aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/c-to-c.py2
-rw-r--r--examples/cdecl.py2
-rw-r--r--examples/explore_ast.py2
-rw-r--r--examples/func_calls.py2
-rw-r--r--examples/func_defs.py2
-rw-r--r--examples/using_cpp_libc.py2
6 files changed, 6 insertions, 6 deletions
diff --git a/examples/c-to-c.py b/examples/c-to-c.py
index acd2cd4..35e1c64 100644
--- a/examples/c-to-c.py
+++ b/examples/c-to-c.py
@@ -13,7 +13,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
from pycparser import parse_file, c_parser, c_generator
diff --git a/examples/cdecl.py b/examples/cdecl.py
index 0e07272..8884591 100644
--- a/examples/cdecl.py
+++ b/examples/cdecl.py
@@ -25,7 +25,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
from pycparser import c_parser, c_ast
diff --git a/examples/explore_ast.py b/examples/explore_ast.py
index 919f44e..24df79f 100644
--- a/examples/explore_ast.py
+++ b/examples/explore_ast.py
@@ -18,7 +18,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
from pycparser import c_parser, c_ast
diff --git a/examples/func_calls.py b/examples/func_calls.py
index f79d47e..f8ff731 100644
--- a/examples/func_calls.py
+++ b/examples/func_calls.py
@@ -13,7 +13,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
from pycparser import c_parser, c_ast, parse_file
diff --git a/examples/func_defs.py b/examples/func_defs.py
index 9522382..c42d5c0 100644
--- a/examples/func_defs.py
+++ b/examples/func_defs.py
@@ -16,7 +16,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
from pycparser import c_parser, c_ast, parse_file
diff --git a/examples/using_cpp_libc.py b/examples/using_cpp_libc.py
index fa9e6a7..1c28c7a 100644
--- a/examples/using_cpp_libc.py
+++ b/examples/using_cpp_libc.py
@@ -13,7 +13,7 @@ import sys
# This is not required if you've installed pycparser into
# your site-packages/ with setup.py
#
-sys.path.insert(0, '..')
+sys.path.extend(['.', '..'])
# Portable cpp path for Windows and Linux/Unix
CPPPATH = '../utils/cpp.exe' if sys.platform == 'win32' else 'cpp'