Created
May 11, 2011 09:29
-
-
Save aseemk/966185 to your computer and use it in GitHub Desktop.
Eco error messages contain meaningless line numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h2>Error reporting</h2> | |
<p> | |
Does the error message for this page report the correct line number? | |
</p> | |
<% para = (phrase) -> %> | |
<p><%= phrase %></p> | |
<% end %> | |
<%- para 'Hello world.' %> | |
<%- para 'What's up doc?' %> | |
<%- para 'Not much, how about you?' %> | |
<p> | |
Good luck finding the error! | |
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_print _safe '<h2>Error reporting</h2>\n\n<p>\n Does the error message for this page report the correct line number?\n</p>\n\n' | |
para = (phrase) -> | |
_capture -> | |
_print _safe '\n <p>' | |
_print phrase | |
_print _safe '</p>\n' | |
_print _safe '\n\n' | |
_print _safe para 'Hello world.' | |
_print _safe '\n' | |
_print _safe para 'What's up doc?' | |
_print _safe '\n' | |
_print _safe para 'Not much, how about you?' | |
_print _safe '\n\n<p>\n Good luck finding the error!\n</p>\n' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment