Skip to content

Commit

Permalink
build: enable ninja.py it import StringIO on Python 3
Browse files Browse the repository at this point in the history
This change supports access to StringIO on both Python 2 and Python 3
  • Loading branch information
cclauss authored Jul 21, 2019
1 parent bacf53d commit e7b38e0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion gyp/pylib/gyp/generator/ninja.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@
import gyp.msvs_emulation
import gyp.MSVSUtil as MSVSUtil
import gyp.xcode_emulation
from cStringIO import StringIO
try:
from cStringIO import StringIO
except ImportError:
from io import StringIO

from gyp.common import GetEnvironFallback
import gyp.ninja_syntax as ninja_syntax
Expand Down

0 comments on commit e7b38e0

Please sign in to comment.