#15495: makemessages excludes all strings from Javascript after a comment
------------------------------------------------+---------------------------
               Reporter:  lrekucki              |         Owner:  nobody
                 Status:  new                   |     Milestone:        
              Component:  Internationalization  |       Version:  SVN   
             Resolution:                        |      Keywords:        
           Triage Stage:  Accepted              |     Has patch:  1     
    Needs documentation:  0                     |   Needs tests:  0     
Patch needs improvement:  0                     |  
------------------------------------------------+---------------------------
Changes (by lrekucki):

  * has_patch:  0 => 1


Comment:

 The patch fixes this particular problem (and some similar to it), but it's
 not too hard to construct a valid JavaScript that gets omited or
 improperly mangled by regexps. Just a few examples:

 {{{
 #!js
 gettext("String"); // This comment won't be caught by pythonize_re and it
 contains "'" which is a string start in Perl
 /*
  * This one will be removed by the patch
  */
 gettext("/* but this one will be too */ 'cause there is no way of
 telling...");
 f(/* ... if it's different from this one */);
 }}}

 The only ''real'' fix is having a JavaScript lexer and (probaly
 simplified) parser instead of a bunch of hacky regexps. No time to do it
 right now, so maybe someone else wants to do it.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/15495#comment:3>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to