Ver código fonte

[python] async and await are reserved keywords in python 3.7

https://docs.python.org/3/whatsnew/3.7.html
Andy Li 7 anos atrás
pai
commit
1c0a4c3e83
1 arquivos alterados com 1 adições e 1 exclusões
  1. 1 1
      src/generators/genpy.ml

+ 1 - 1
src/generators/genpy.ml

@@ -68,7 +68,7 @@ module KeywordHandler = struct
 	let kwds =
 		let h = Hashtbl.create 0 in
 		List.iter (fun s -> Hashtbl.add h s ()) [
-			"and"; "as"; "assert"; "break"; "class"; "continue"; "def"; "del"; "elif"; "else"; "except"; "exec"; "finally"; "for";
+			"and"; "as"; "assert"; "async"; "await"; "break"; "class"; "continue"; "def"; "del"; "elif"; "else"; "except"; "exec"; "finally"; "for";
 			"from"; "global"; "if"; "import"; "in"; "is"; "lambda"; "not"; "or"; "pass"; " raise"; "return"; "try"; "while";
 			"with"; "yield"; "None"; "True"; "False";
 		];