Does Drupal have a native stackbased UBB parser? I can't seem to locate one in the core, nor in the module download section. If not, how does Drupal parse UBB - using regex?

I really need stackbased (because of easier maintenance and more error-prone) UBB parsing, so if none is available, I would have to educate myself and build one (obviously sharing with the community).