Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
parser-quantum-espresso
Commits
ff4cc112
Commit
ff4cc112
authored
Sep 29, 2016
by
Henning Glawe
Browse files
annotateFile as argument to constructor
parent
4a2265c0
Changes
1
Hide whitespace changes
Inline
Side-by-side
parser/parser-quantum-espresso/FortranNamelistParser.py
View file @
ff4cc112
...
...
@@ -105,11 +105,11 @@ cRE_end_newline = re.compile(r'(.*?)(\n*)$')
class
FortranNamelistParser
(
object
):
"""Parser for Fortran 90 Namelists
"""
def
__init__
(
self
,
file_path
):
def
__init__
(
self
,
file_path
,
annotateFile
=
None
):
self
.
input_tree
=
{}
self
.
file_path
=
file_path
self
.
state
=
self
.
state_root
self
.
__annotateFile
=
sys
.
stdout
self
.
__annotateFile
=
annotateFile
self
.
__nl_group
=
None
self
.
__target
=
None
self
.
__subscript
=
None
...
...
@@ -451,5 +451,5 @@ class FortranNamelistParser(object):
pass
if
__name__
==
"__main__"
:
parser
=
FortranNamelistParser
(
sys
.
argv
[
1
])
parser
=
FortranNamelistParser
(
sys
.
argv
[
1
]
,
annotateFile
=
sys
.
stdout
)
parser
.
parse
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment