--- functions.php	2010-07-09 04:14:17.000000000 +0200
+++ functions-patch.php	2010-07-09 04:13:59.000000000 +0200
@@ -4179,6 +4179,17 @@
 		$all_headers = $default_headers;
 	}
 
+	$tmp_data = ''; 
+	$tokens = token_get_all( "<?php\n" . $file_data ); // fake being PHP code
+	foreach ( $tokens as $token ) { 
+	    if ( ( $token[0] == T_COMMENT || $token[0] == T_DOC_COMMENT )
+	        && !preg_match( "/^#/", $token[1] ) ) { 
+	        $tmp_data .= $token[1];
+	    }   
+	}
+	$file_data = $tmp_data;
 
 	foreach ( $all_headers as $field => $regex ) {
 		preg_match( '/' . preg_quote( $regex, '/' ) . ':(.*)$/mi', $file_data, ${$field});

