Mercurial > python-compiler.rs
comparison src/ast_dump.rs @ 72:7ac23f4336b1
Add ast.AsyncWith.
author | Bastien Orivel <eijebong@bananium.fr> |
---|---|
date | Mon, 13 Jun 2016 18:09:15 +0200 |
parents | 2c1e2ce41263 |
children | 2a6629ea82b5 |
comparison
equal
deleted
inserted
replaced
71:2c1e2ce41263 | 72:7ac23f4336b1 |
---|---|
352 None => String::new(), | 352 None => String::new(), |
353 Some(msg) => format!(", {}", msg.to_string()) | 353 Some(msg) => format!(", {}", msg.to_string()) |
354 } | 354 } |
355 ) | 355 ) |
356 }, | 356 }, |
357 stmt::With(items, body) => { | 357 stmt::With(items, body, async) => { |
358 format!("{}with {}:\n{}", | 358 format!("{}{}with {}:\n{}", |
359 current_indent, | 359 current_indent, |
360 if async { "async " } else { "" }, | |
360 vec_to_strings_vec(items).join(", "), | 361 vec_to_strings_vec(items).join(", "), |
361 statements_to_string(indent, body) | 362 statements_to_string(indent, body) |
362 ) | 363 ) |
363 }, | 364 }, |
364 stmt::Raise(exc, cause) => { | 365 stmt::Raise(exc, cause) => { |