Пример #1
0
        private GenContext(string directory, AssemblyName aname, string extension, bool createDynInitHelper, string sourceName)
        {
            // TODO: Make this settable from a *debug* flag
#if DEBUG
            _isDebuggable = true;
#else
            _isDebuggable = false;
#endif

            _assyGen = new AssemblyGen(aname, directory, extension, _isDebuggable);
            if (createDynInitHelper)
            {
                _dynInitHelper = new DynInitHelper(_assyGen, GenerateName());
            }

            _docInfo = Expression.SymbolDocument(sourceName);

            _moduleBuilder = _assyGen.ModuleBuilder;

            Path = ComputeAssemblyPath(directory, aname.Name, extension);

#if NET461
            if (_isDebuggable)
            {
                _docWriter = ModuleBuilder.DefineDocument(sourceName, ClojureContext.Default.LanguageGuid, ClojureContext.Default.VendorGuid, Guid.Empty);
            }
#endif
        }
Пример #2
0
 public GenContext(string assyName, string extension, string directory, bool createDynInitHelper)
 {
     AssemblyName aname = new AssemblyName(assyName);
     _assyGen = new AssemblyGen(aname, directory, extension, true);
     if ( createDynInitHelper )
         _dynInitHelper = new DynInitHelper(_assyGen, "__InternalDynamicExpressionInits");
 }
Пример #3
0
        private GenContext(string sourceName, string assyName, string extension, string directory, bool createDynInitHelper)
        {
            // TODO: Make this settable from a *debug* flag
#if DEBUG
            _isDebuggable = true;
#else
            _isDebuggable = false;
#endif
            if (directory != null)
            {
                if (directory.Length > 0)  //&& directory != ".")
                {
                    assyName = assyName.Replace("/", ".");
                }
            }

            AssemblyName aname = new AssemblyName(assyName);
            _assyGen = new AssemblyGen(aname, directory, extension, _isDebuggable);
            if (createDynInitHelper)
            {
                _dynInitHelper = new DynInitHelper(_assyGen, GenerateName());
            }
            if (_isDebuggable)
            {
                _docWriter = ModuleBuilder.DefineDocument(sourceName, ClojureContext.Default.LanguageGuid, ClojureContext.Default.VendorGuid, Guid.Empty);
            }
            _docInfo = Expression.SymbolDocument(sourceName);
        }
Пример #4
0
        private GenContext(string directory, AssemblyName aname, string extension, bool createDynInitHelper, string sourceName)
        {
            // TODO: Make this settable from a *debug* flag
            #if DEBUG
            _isDebuggable = true;
            #else
            _isDebuggable = false;
            #endif

            _assyGen = new AssemblyGen(aname, directory, extension, _isDebuggable);
            if ( createDynInitHelper )
                _dynInitHelper = new DynInitHelper(_assyGen, GenerateName());
            if (_isDebuggable)
                _docWriter = ModuleBuilder.DefineDocument(sourceName, ClojureContext.Default.LanguageGuid, ClojureContext.Default.VendorGuid, Guid.Empty);
            _docInfo = Expression.SymbolDocument(sourceName);
        }
Пример #5
0
        private GenContext(string assyName, string extension, string directory, bool createDynInitHelper)
        {
            // TODO: Make this settable from a *debug* flag
            #if DEBUG
            _isDebuggable = true;
            #else
            _isDebuggable = false;
            #endif
            if (directory != null)
            {
                if (directory.Length > 0 && directory != ".")
                    assyName = assyName.Replace("/", ".");
            }

            AssemblyName aname = new AssemblyName(assyName);
            _assyGen = new AssemblyGen(aname, directory, extension, _isDebuggable);
            if ( createDynInitHelper )
                _dynInitHelper = new DynInitHelper(_assyGen, "__InternalDynamicExpressionInits");
        }
Пример #6
0
        private GenContext(string assyName, string extension, string directory, bool createDynInitHelper)
        {
            // TODO: Make this settable from a *debug* flag
#if DEBUG
            _isDebuggable = true;
#else
            _isDebuggable = false;
#endif
            if (directory != null)
            {
                if (directory.Length > 0 && directory != ".")
                {
                    assyName = assyName.Replace("/", ".");
                }
            }

            AssemblyName aname = new AssemblyName(assyName);
            _assyGen = new AssemblyGen(aname, directory, extension, _isDebuggable);
            if (createDynInitHelper)
            {
                _dynInitHelper = new DynInitHelper(_assyGen, "__InternalDynamicExpressionInits");
            }
        }