mirror of
https://github.com/AdaCore/langkit.git
synced 2026-02-12 12:28:12 -08:00
This will make it possible to preserve a stable image after we enable unit filename canonicalization (i.e. getting an absolute path). TN: R206-016
15 lines
302 B
Python
15 lines
302 B
Python
from __future__ import absolute_import, division, print_function
|
|
|
|
print('main.py: Running...')
|
|
|
|
|
|
import os.path
|
|
|
|
import libfoolang
|
|
|
|
|
|
ctx = libfoolang.AnalysisContext()
|
|
u = ctx.get_from_buffer('foo.txt', 'example')
|
|
print('Unit filename: {}'.format(os.path.basename(u.filename)))
|
|
print('main.py: Done.')
|