Skip to content

Commit

Permalink
It is not necessary to define default values to datatypes, they will …
Browse files Browse the repository at this point in the history
…be caught the schema.cfg file
  • Loading branch information
macabeus authored and Elvish-Hunter committed Mar 22, 2016
1 parent a79de2c commit aeb2dc6
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions data/tools/wesnoth/wmlgrammar.py
Expand Up @@ -13,13 +13,7 @@
class Grammar(object):
def __init__(self, schema):
schema = schema.get_first("schema")
self.datatypes = {
"boolean": re.compile("^(yes|no|true|false|on|off)$"),
# "character" : re.compile("^.$"),
"float": re.compile("^(\\+|-)?[0-9]+(\.[0-9]*)?$"),
"integer": re.compile("^(\\+|-)?[0-9]+$"),
"string": re.compile(".*"),
}
self.datatypes = {}
self.elements = {}
self.categories = collections.defaultdict(list)
for type in schema.get_all_text():
Expand Down

0 comments on commit aeb2dc6

Please sign in to comment.