1*11be35a1SLionel Sambuc# Let's have some fun -- try to match a C comment. 2*11be35a1SLionel Sambuc# first the obvious, which looks okay at first glance... 3*11be35a1SLionel Sambuc/\*.*\*/ - /*x*/ /*x*/ 4*11be35a1SLionel Sambuc# but... 5*11be35a1SLionel Sambuc/\*.*\*/ - /*x*/y/*z*/ /*x*/y/*z*/ 6*11be35a1SLionel Sambuc# okay, we must not match */ inside; try to do that... 7*11be35a1SLionel Sambuc/\*([^*]|\*[^/])*\*/ - /*x*/ /*x*/ 8*11be35a1SLionel Sambuc/\*([^*]|\*[^/])*\*/ - /*x*/y/*z*/ /*x*/ 9*11be35a1SLionel Sambuc# but... 10*11be35a1SLionel Sambuc/\*([^*]|\*[^/])*\*/ - /*x**/y/*z*/ /*x**/y/*z*/ 11*11be35a1SLionel Sambuc# and a still fancier version, which does it right (I think)... 12*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x*/ /*x*/ 13*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x*/y/*z*/ /*x*/ 14*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x**/y/*z*/ /*x**/ 15*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x****/y/*z*/ /*x****/ 16*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x**x*/y/*z*/ /*x**x*/ 17*11be35a1SLionel Sambuc/\*([^*]|\*+[^*/])*\*+/ - /*x***x/y/*z*/ /*x***x/y/*z*/ 18