[PATCH] D68802: [LNT] Python 3 support: fix writing report to tmp file
Thomas Preud'homme via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 5 05:09:59 PST 2019
thopre marked 3 inline comments as done.
thopre added inline comments.
================
Comment at: lnt/util/ImportData.py:341-343
+ fp = os.fdopen(fd, "w")
+ fp.write(data)
+ fp.close()
----------------
PrzemekWirkus wrote:
> PrzemekWirkus wrote:
> > This can be simplified to:
> >
> > with os.fdopen(fd, "w") as fp:
> > fp.write(data)
> >
> > ?
> Got that code block wrong last time:
> ```
> with os.fdopen(fd, "w") as fp:
> fp.write(data)
> ```
Sorry, only saw that after committing the change. I've created https://reviews.llvm.org/D71058 for it
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D68802/new/
https://reviews.llvm.org/D68802
More information about the llvm-commits
mailing list