Re: empty <% %> = different errors...
Jonathan Swartz <[email protected]> Sat, 1 Mar 2014 07:14:27 -0800
| Newsgroups | gmane.comp.web.mason.user |
|---|---|
| Message-ID | <[email protected]> |
That's a funny one! Fixed in the next release. (Empty tags will be forbidden w/consistent error message.) Thanks Jon On Feb 28, 2014, at 11:34 AM, A Kobame <[email protected]> wrote: > Hi all, > > Searched a half hour the error in the next (now shortened) component. > > <%init> > $.title = "TITLE"; > </%init> > <%filter SomeFilter><% $yield->() %></%filter> > <% %> > > % $.SomeFilter {{ > some long text here... > % }} > > % $.SomeFilter {{ > some long text here... > <% $.title %> > some long text here... > % }} > > > > Sure, now - when it is shortened, the error is clearly visible - the empty <% %> > > What is strange, the error-message - what says: > > '}}' without matching '{{' at /.../comps/tmp/index.mc line 15 > > the line15 is the closing }} of the second filter. When removed the empty <% %> the page is rendered OK. > > So, incorrect error detection. > > For curiosity, when remove the correct <% $.title %>, the error message changes to usable one: > > whitespace required after '<%' at /.../comps/tmp/index.mc line 5 > > After this, i checked some variants: > > <%%> - (without space) the error is: '<%' without matching '%>' at > <% %> - (one space): whitespace required after '<%' at > <% %> - (two or more spaces): whitespace required before '%>' at > > IMHO, if the <% \s* %> construction is intentionaly not allowed, it should give a consistent error message - or at least - should NOT detected as an filter }} closing error. > > Lastly - IMHO the <% \s* %> should be rendered as an EMPTY string. > > ak. > > ------------------------------------------------------------------------------ > Flow-based real-time traffic analytics software. Cisco certified tool. > Monitor traffic, SLAs, QoS, Medianet, WAAS etc. with NetFlow Analyzer > Customize your own dashboards, set traffic alerts and generate reports. > Network behavioral analysis & security monitoring. All-in-one tool. > http://pubads.g.doubleclick.net/gampad/clk?id=126839071&iu=/4140/ostg.clktrk_______________________________________________ > Mason-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/mason-users ------------------------------------------------------------------------------ Flow-based real-time traffic analytics software. Cisco certified tool. Monitor traffic, SLAs, QoS, Medianet, WAAS etc. with NetFlow Analyzer Customize your own dashboards, set traffic alerts and generate reports. Network behavioral analysis & security monitoring. All-in-one tool. http://pubads.g.doubleclick.net/gampad/clk?id=126839071&iu=/4140/ostg.clktrk _______________________________________________ Mason-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mason-users