sgzwiz / brython

Automatically exported from code.google.com/p/brython
BSD 3-Clause "New" or "Revised" License
0 stars 1 forks source link

Script indentation should be that of first line #6

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Reported on the list in French

In a page like

<html>
    <head>
        <title>Brython test</title>
        <script src="brython.js"></script>
    </head>
    <body onLoad="brython()">
        <script type="text/python">
        def HelloWorld():
            alert("Hello world !")

        HelloWorld()
        </script>
    </body>
</html>

an IndentationError is raised because the first line of the script is indented

François Dion suggested not to raise an exception and to consider that the 
first line indentation is the base for the whole script

Original issue reported on code.google.com by pierre.q...@gmail.com on 16 Dec 2012 at 9:39

GoogleCodeExporter commented 9 years ago
Fixed in version 20121220

Original comment by pierre.q...@gmail.com on 21 Dec 2012 at 7:40