summaryrefslogtreecommitdiffstats
path: root/generic/tclMain.c
Commit message (Collapse)AuthorAgeFilesLines
* Micro-optimization: Use TclGetStringFromObj in stead of Tcl_GetStringFromObj ↵jan.nijtmans2016-07-081-4/+4
| | | | in many places where possible.
* Remove Tcl_Main() function, since it's no longer being used: It has been a ↵jan.nijtmans2016-06-291-18/+5
| | | | macro already for ages.
* Tcl_SetVar -> Tcl_SetVar2 and comparable replacements, eliminating functions ↵jan.nijtmans2016-06-291-2/+4
| | | | which are deprecated.
* Align comment. Remove some end-of-line spacing. No functional changes.jan.nijtmans2015-09-281-2/+2
|\
* \ Fix [00189c4afcb9e2586301d711f71383e48817a72d|00189c4afc]: Allow semi-static ↵jan.nijtmans2015-08-191-0/+3
|\ \ | |/ | | | | UCRT build on Windows with VC 14.0
| * Fix [00189c4afcb9e2586301d711f71383e48817a72d|00189c4afc]: Allow semi-static ↵jan.nijtmans2015-08-191-0/+3
| | | | | | | | UCRT build on Windows with VC 14.0
* | Eliminate all usage of WIN32 and __WIN32__ macros: Some compilers (e.g. ↵jan.nijtmans2014-02-101-1/+1
| | | | | | | | | | Clang/LLVM) don't define it, and _WIN32 is much more portable anyway. See: [http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system#WindowsCygwinnonPOSIXandMinGW]
* | Bug [9b2e636361]: Tcl_CreateInterp() needs initialized encodings.jan.nijtmans2013-06-271-1/+3
|\ \ | |/
| * Proposed solution for [9b2e636361]jan.nijtmans2013-06-261-2/+3
| |
* | eliminate unnecessary TEXT() macrosjan.nijtmans2012-09-231-2/+2
| |
* | Minor changes to improve style (C89 declarations, consistent indentation,dkf2012-08-071-46/+52
| | | | | | | | clarification of #endifs, reduction of unnecessary casts, use of array syntax for reading array elements, etc.)
* | * generic/tclUtil.c (TclDStringToObj): Added internal function to makedkf2012-04-251-10/+13
| | | | | | | | the fairly-common operation of converting a DString into an Obj a more efficient one.
* | [RFE 1711975]: Tcl_MainEx() (like Tk_MainEx())jan.nijtmans2011-09-061-4/+5
|\ \
| * | Tcl_MainEx() (like Tk_MainEx())rfe_1711975jan.nijtmans2011-08-301-1/+2
|/ /
* | Fixed the C99/C++ comments introduced by [8d3f0fb215] which break strict C89 ↵andreask2011-08-161-2/+2
| | | | | | | | compilers (AIX, cough, cough)
* | compiler error on Windows: there should be only one ↵jan.nijtmans2011-08-101-1/+1
| | | | | | | | TclFullFinalizationRequested function
* | [Bug 2919042] Restore "valgrindability" of Tcl that was lost by the ↵ferrieux2011-08-091-15/+72
| | | | | | | | streamlining of [exit], by conditionally forcing a full Finalize: use -DPURIFY or ::env(TCL_FINALIZE_ON_EXIT)
* | [Patch #3124683]: platform specific stuff in (tcl|tk)Main.cjan.nijtmans2011-03-171-155/+130
| |
* | Adjust ckalloc/ckfree macros to greatly reduce number of explicit casts indkf2011-03-121-3/+2
| | | | | | rest of Tcl source code. No ABI change. API change *should* be harmless.
* | Now that we're no longer using SCM based on RCS, the RCS Keyword linesdgp2011-03-021-2/+0
|\ \ | |/ | | cause more harm than good. Purged them (except in zlib files).
| * Now that we're no longer using SCM based on RCS, the RCS Keyword lines causedgp2011-03-021-2/+0
| |\ | | | | | | more harm than good. Purged them.
| | * Now that we're no longer using SCM based on RCS, the RCS Keyword lines causedgp2011-03-011-2/+0
| | | | | | | | | more harm than good. Purged them.
| | * * generic/tclMain.c (Tcl_Main): Corrected flaw that requireddgp2006-05-051-67/+67
| | | | | | | | | | | | | | | | | | * tests/main.test: (Tcl_Main-4.5): processing of one interactive command before passing control to the loop routine registered with Tcl_SetMainLoop() [Bug 1481986].
| | * * generic/tclBasic.c:Miguel Sofer2005-10-231-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclBinary.c: * generic/tclCmdAH.c: * generic/tclCmdIL.c: * generic/tclCmdMZ.c: * generic/tclExecute.c: * generic/tclLink.c: * generic/tclMain.c: * generic/tclProc.c: * generic/tclScan.c: * generic/tclTest.c: * generic/tclVar.c: * mac/tclMacInit.c: * unix/tclUnixInit.c: * win/tclWinInit.c: Insure that the core never calls TclPtrSetVar, Tcl_SetVar2Ex, Tcl_ObjSetVar2 or Tcl_SetObjErrorCode with a 0-ref new value. It is not possible to handle error returns correctly in that case [Bug 1334947], one has the choice of leaking the object in some cases, or else risk crashing in some others.
| | * * generic/tclMain.c: Separate encoding conversion of command linedgp2005-09-301-26/+23
| | | | | | | | | | | | arguments from list formatting. [Bug 1306162].
| * | * generic/tclCmdAH.c: Fix cases where value returned bydgp2010-09-231-1/+2
| | | | | | | | | | | | | | | | | | * generic/tclEvent.c: Tcl_GetReturnOptions() was leaked. * generic/tclMain.c: Thanks to Jeff Hobbs for discovery of the anti-pattern to seek and destroy.
* | | reverted previous commit: it has effect on the Windows consolenijtmans2010-11-151-23/+33
| | |
* | | Eliminate use of the function Tcl_WinTCharToUtf in generic codenijtmans2010-11-151-33/+23
| | |
* | | fix TCL_ASCII_MAIN usage, as the name suggestsnijtmans2010-11-051-5/+7
| | |
* | | * generic/tclMain.c: Added missing conditional on _WIN32 around codeKevin B Kenny2010-11-041-2/+2
| | | | | | | | | | | | | | | that messes around with the definition of _UNICODE, to correct a badly broken Unix build from Jan's last commit.
* | | [FRQ 491789]: "setargv() doesn't support a unicode cmdline" implemented for ↵nijtmans2010-11-041-10/+26
| | | | | | | | | | | | Tcl on MSVC++
* | | tclMain.c: make compilable with -DUNICODE as wellnijtmans2010-09-291-24/+72
| | |
* | | * generic/tclCmdAH.c: Fix cases where value returned bydgp2010-09-231-1/+2
| | | | | | | | | | | | | | | | | | * generic/tclEvent.c: Tcl_GetReturnOptions() was leaked. * generic/tclMain.c: Thanks to Jeff Hobbs for discovery of the anti-pattern to seek and destroy.
* | | Unnecessary TCL_STORAGE_CLASS re-definition.nijtmans2010-04-301-4/+1
| | | | | | | | | | | | | | | It was used for an ancient dummy reference to Tcl_LinkVar(), but that's already gone since 2002-05-29.
* | | * generic/tclMain.c (Tcl_Main): [Bug 801429]: Factor out the holding of thedkf2010-02-271-34/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | client-installed main loop function into thread-specific data. ***POTENTIAL INCOMPATIBILITY*** Code that previously tried to set the main loop from another thread will now fail. On the other hand, there is a fairly high probability that such programs would have been failing before due to the lack of any kind of inter-thread memory barriers guarding accesses to this part of Tcl's state.
* | | Pure whitespace changes, changing to follow Engineering Manual style.dkf2010-02-241-11/+11
| | |
* | | TIP #338 IMPLEMENTATIONdgp2008-12-151-118/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/AppInit.c: Made routines Tcl_SetStartupScript and * doc/Tcl_Main.3: Tcl_GetStartupScript public. Removed all * generic/tcl.h: internal stub access to Tcl*Startup* routines, * generic/tclInt.decls: and removed their implementations. Their * generic/tclMain.c: function can now be completely performed with the new public interface. *** POTENTIAL INCOMPATIBILITY for callers of the internal Tcl*Startup* routines. *** * generic/tclIntDecls.h: make genstubs * generic/tclStubInit.c:
* | | Reduce the number of (pointless) type-casts.dkf2008-10-021-38/+39
| | |
* | | Get rid of pre-C89-isms (esp. CONST vs const).dkf2008-04-271-11/+13
|/ /
* | merge stable branch onto HEADdgp2007-12-131-1/+1
| |
* | * generic/tclMain.c: Corrected the logic of dropping the lastdgp2007-08-211-17/+27
| | | | | | | | | | * tests/main.test: newline from an interactively typed command. [Bug 1775878].
* | corrected botched indentsdgp2007-04-241-38/+38
| |
* | Handle creation of Tcl_Objs from constant strings better (easier to use, moredkf2007-04-101-3/+3
| | | | | | | | efficient). After [Patch 1529526] (afredd)
* | whitespacedas2006-11-231-5/+5
| |
* | TIP#270 IMPLEMENTATIONdgp2006-11-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tcl.decls: New public routines Tcl_ObjPrintf, * generic/tclStringObj.c: Tcl_AppendObjToErrorInfo, Tcl_Format, * generic/tclInt.h: Tcl_AppendLimitedToObj, Tcl_AppendFormatToObj and Tcl_AppendPrintfToObj. Former internal versions removed. * generic/tclDecls.h: make genstubs * generic/tclStubInit.c: * generic/tclBasic.c: Updated callers. * generic/tclCkalloc.c: * generic/tclCmdAH.c: * generic/tclCmdIL.c: * generic/tclCmdMZ.c: * generic/tclCompExpr.c: * generic/tclCompile.c: * generic/tclDictObj.c: * generic/tclExecute.c: * generic/tclIORChan.c: * generic/tclIOUtil.c: * generic/tclMain.c: * generic/tclNamesp.c: * generic/tclObj.c: * generic/tclPkg.c: * generic/tclProc.c: * generic/tclStrToD.c: * generic/tclTimer.c: * generic/tclUtil.c: * unix/tclUnixFCmd.c:
* | * generic/tclBasic.c: Further revised TclAppendPrintToObj() anddgp2006-11-021-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclCkalloc.c: TclObjPrintf() routines to panic when unable * generic/tclCmdAH.c: to complete their formatting operations, rather * generic/tclCmdIL.c: than report an error message. This means an * generic/tclCmdMZ.c: interp argument for error message recording is * generic/tclDictObj.c: no longer needed, further simplifying the * generic/tclExecute.c: interface for callers. * generic/tclIORChan.c: * generic/tclIOUtil.c: * generic/tclInt.h: * generic/tclMain.c: * generic/tclNamesp.c: * generic/tclParseExpr.c: * generic/tclPkg.c: * generic/tclProc.c: * generic/tclStringObj.c: * generic/tclTimer.c: * generic/tclUtil.c: * unix/tclUnixFCmd.c:
* | * generic/tclBasic.c: Refactored and renamed the routinesdgp2006-10-311-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclCkalloc.c: TclObjPrintf, TclFormatObj, and * generic/tclCmdAH.c: TclFormatToErrorInfo to a new set of * generic/tclCmdIL.c: routines TclAppendPrintfToObj, * generic/tclCmdMZ.c: TclAppendFormatToObj, TclObjPrintf, and * generic/tclDictObj.c: TclObjFormat, with the intent of making * generic/tclExecute.c: the latter list, plus TclAppendLimitedToObj * generic/tclIORChan.c: and TclAppendObjToErrorInfo, public via * generic/tclIOUtil.c: a revised TIP 270. * generic/tclInt.h: * generic/tclMain.c: * generic/tclNamesp.c: * generic/tclParseExpr.c: * generic/tclPkg.c: * generic/tclProc.c: * generic/tclStringObj.c: * generic/tclTimer.c: * generic/tclUtil.c: * unix/tclUnixFCmd.c:
* | * generic/tclMain.c (Tcl_Main): Corrected flaw that requireddgp2006-05-051-111/+111
| | | | | | | | | | | | * tests/main.test: (Tcl_Main-4.5): processing of one interactive command before passing control to the loop routine registered with Tcl_SetMainLoop() [Bug 1481986].
* | ANSIfy. Also converted some deeply nested code to a less nested form for ↵dkf2005-11-011-46/+43
| | | | | | | | easier reading.
* | * generic/tcl.h: Fix for bug #1256937 - correctly decoratepatthoyts2005-10-141-2/+2
| | | | | | | | * generic/tclMain.c: imported functions from msvcrt in static builds.