Commit Graph

247 Commits

Author SHA1 Message Date
Timothee Cour
1f1d85bb9c reuse config/build_config.txt for all bootstrap scripts (posix + windows + ci); use build_all.bat in 1 CI, fix bug in build_all.bat (#17899)
* reuse config/build_config.txt for all bootstrap scripts (posix + windows + ci)
* ci_docs: use build_all.bat in CI (just in that pipeline) to ensure it keeps working
* fixup
* fix pre-existing bug in build_all.bat
* fixup
* cp => copy /y
* auto-generate build_all.bat, build_all.sh
* fixup
2021-05-01 07:24:41 +02:00
Andrey Makarov
8f79bc5f3d add RST highlighting for command line / shells (also fixes #16858) (#17789) 2021-04-21 16:57:54 +02:00
Andrey Makarov
2150cd1826 restyle RST option lists (#17637)
* WIP: restyle RST option lists

* apply similar style to Latex

* fix tests

* minor visual tweaks

* update tests

* remove leftover comments
2021-04-10 09:49:01 +02:00
Emery Hemingway
8aa5991bea Genode platform fixes (#17521)
* Genode: move dyncall failures to runtime

Do not use the "error" pragma to warn that dynamic library loading is
not implemented, print a message at runtime and exit.

* Genode: use stricter dataspace type in page allocator

* Genode: remove compiler configuration from nim.cfg

Self-hosting Nim is not supported on Genode and defining the
cross-compilation environment can be done externally.

* Genode: use new mutex API

* Genode: call nim_component_construct as a C procedure

* Genode: implement echo for NimStringV2
2021-04-09 16:29:10 +02:00
flywind
f25384adc8 remove deprecated config (#17269) 2021-03-05 20:02:21 +01:00
Andrey Makarov
02f4464058 RST heading improvements (fix #17091) (#17195) 2021-03-02 16:41:10 +01:00
Timothee Cour
31bb67a309 add -d:nimStrictMode in CI to keep code from regressing; fixes ConvFromXtoItselfNotNeeded, UnusedImport notes (#16764) 2021-02-17 19:30:09 +01:00
Timothee Cour
b9994925f5 remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 (#16918)
* nimNoArrayToCstringConversion deadcode
* nimbabel deadcode
* nimHasalignOf deadcode
* nimvarargstyped deadcode
* nimhygiene deadcode
* nimNewTypedesc deadcode
* nimlocks deadcode
* nimHasCppDefine deadcode
* nimHasRunnableExamples deadcode
* nimHasNilChecks deadcode
* nimSymKind deadcode
* minor macros refactoring
* nimVmEqIdent deadcode
* nimNoNil deadcode
* nimNoZeroTerminator deadcode
* nimHasSymOwnerInMacro deadcode
* nimVmExportFixed deadcode
* nimNewRuntime deadcode
* nimAshr deadcode
* nimUncheckedArrayTyp deadcode
* nimHasTypeof deadcode
* nimErrorProcCanHaveBody deadcode
* nimHasHotCodeReloading deadcode
* nimHasSignatureHashInMacro deadcode
* nimHasDefault deadcode
* nimMacrosSizealignof deadcode
2021-02-17 09:32:36 +01:00
Andrey Makarov
35bd39a9d0 RST: implement footnotes and citations (#16960)
* RST: implement footnotes and citations
* manual fixup of nimdoc.out.css
* remove unused code
* shorter printing code
* Update lib/packages/docutils/rst.nim

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2021-02-15 14:12:40 +01:00
Timothee Cour
44f672a515 fix #9102 docgen: sidebar now shows proc signatures instead of encoding (#16857) 2021-01-29 08:42:19 +01:00
Timothee Cour
e112974920 fix #16752: threadvar now works with importcpp types; osx now uses native TLS (--tlsEmulation:off), which can be orders of magnitude faster (#16750)
* osx now uses native TLS, which can be orders of magnitude faster

* add {.cppNonPod.}

* improve test

* changelog, docs, disable part of windows test
2021-01-27 22:35:43 +01:00
Timothee Cour
2e5254ff27 fix config/nim.cfg: @if not bsd or haiku: was buggy (#16748) 2021-01-19 08:25:21 +01:00
Andrey Makarov
fd5c8ef208 RST: implement internal targets (#16614) 2021-01-11 19:51:04 +01:00
Andrey Makarov
2bdc479622 RST: implement admonitions (#16438) 2020-12-27 11:16:12 +01:00
Andrey Makarov
e843492b13 doc/rst2html: some few fixes for enumerated and bullet lists (#16295)
* fix bullet/enumarated lists with many blank lines
* fix enumerated list parsing
* fix parse failure when next line after list empty
* implement arbitrary start of enumerator
* check that enumerators are in order
* remove redundant start=x if x=1 or a
* add some doc on implemented features
* update start in rst_examples.rst
* allow upper-case letters + more docs
2020-12-14 18:10:39 +01:00
Sebastian Reinhard
93b6fac468 nimdoc: Initialize theme switch and pragma dots on DOMContentLoaded (#16247)
The default HTML template for nimdoc currently initializes the dark mode switch and pragma dots when the onload event is fired. But since the onload event does not fire until all external resources (images, stylesheets, fonts, etc.) have been loaded, the light theme is shown for a brief moment before the document is fully loaded, and it switches to the dark theme. This is quite jarring, especially on slower internet connections. So let's instead initialize these things on the DOMContentLoaded event, which is fired right after the document has been parsed and the initial DOM structure is ready. This means that we now display the dark mode immediately, without having to wait for external resources to load first.

For reference, see:
- https://developer.mozilla.org/en-US/docs/Web/API/Window/load_event
- https://developer.mozilla.org/en-US/docs/Web/API/Window/DOMContentLoaded_event

I have updated the snapshot tests in `nimdoc/`, and done some manual testing of both the theme switch and the pragma dots, to confirm that this does not break anything. Please let me know if I've missed anything.
2020-12-06 10:13:19 +01:00
Timothee Cour
2cb484cefb followup #15642: make source + edit also work with stdlib (which uses -d:boot) (#15684) 2020-10-22 12:02:18 -07:00
Miran
d8a6b0b04e [backport: 1.4] Better linebreaks (#15658) 2020-10-22 12:16:19 +02:00
Timothee Cour
0979524137 add Source+Edit links on top of every docgend file (#15642) 2020-10-22 10:44:28 +02:00
narimiran
fc90eb9f27 change case in nimdoc [ci skip] 2020-10-14 09:26:44 +02:00
Timothee Cour
0c0f86b2c5 reference fusion docs (#15562) 2020-10-14 09:25:28 +02:00
Miran
112b11c154 group procs of the same name in TOC (#15487)
* group procs of the same name in TOC

* correctly show `sink` parameters in TOC

* no need to reinvent the wheel - `mgetorPut` exists

* better setting of text color [ci skip]

* fix CSS for better alignment
2020-10-05 17:03:14 +02:00
Miran
cbd78ec1f6 close #6071, remove the mentions of deprecated docSeeSrcUrl (#15350) 2020-09-17 19:55:18 +02:00
Euan
e4e4931432 Change clibdir and cincludes for NetBSD (#15102) 2020-07-28 12:01:25 -04:00
Manuel Bojato
04232d92cd Fix theme switch load from local storage (#14897)
* fix theme switch load from local storage

* Fix tests

Co-authored-by: Clyybber <darkmine956@gmail.com>
2020-07-10 15:06:07 +02:00
Tomohiro
61a6098f2d Limit number of error messages from gcc/clang backend (#14852)
* Limit number of error messages from backend

* Avoid duplication of -fmax-errors

* make tests/misc/trunner.nim success
2020-07-07 10:22:10 +02:00
Juan Carlos
74d1f25010 Clean out oldast (#14837)
* Clean out old Deprecated CLI switch
* Update to remove --oldast CLI option
2020-06-30 10:01:25 +02:00
Euan
1bc2e19498 Set cincludes and clibdir for FreeBSD, OpenBSD and NetBSD. (#14680) 2020-06-16 11:44:28 +02:00
Timothee Cour
3cf88c2b49 walkDirRecFilter, update doc CI filter, compiler/index.nim for docs + various other fixes (#14501)
* update doc CI filter to include the files mostly likely to require doc rebuild
* remove code duplication in ./config/nimdoc.cfg; show link to compiler docs, various fixes
* walkDirRecFilter, factor nativeToUnixPath workaround
* glob for getRst2html
* docslocal: 40s to build all docs
* revert code dedup in github actions which did not work alas...
* fixups
2020-06-01 19:21:41 +02:00
Timothee Cour
58282547f6 fix #6583, fix #14376, index+search now generated for all projects, many bug fixes with nim doc (#14324)
* refs #6583 fix nim doc output
* changelog
* change default for outDir when unspecified
* cleanups
* --project implies --index
2020-05-25 13:25:40 +02:00
cooldome
e86a6d24d5 vcc fix (#14222)
Co-authored-by: cooldome <ariabushenko@bk.ru>
2020-05-04 19:42:29 +02:00
Keithcat1
d27bc03b21 Add LTO support for most compilers and do some VCC fixes (#14013)
* Added LTO in nim.cfg, added /link in extccomp.nim and other fixes

* Fix line endings

* Fix line endings, for real this time. Almost certainly. Like, 95% certain.

* Removed /MD from extccom.nim VCC comiler
2020-04-22 23:56:43 +02:00
Euan
7828199827 #12103 - CI for OpenBSD (#12105)
* Working on OpenBSD CI
* Condense steps into 2 steps to make output easier to follow.
* Move up one directory after csources build.
* Remove FreeBSD build manifest and add OpenBSD test ignores for coroutines and hot code reloading.
* If runCI fails, run the test results script.
* Add email trigger for build failure
* Remove .git from repository URL
* Disable SFML test on OpenBSD
* Disable tgetaddrinfo on OpenBSD as only UDP and TCP protocols are supported.
* Remove getFilePermissions as it causes CI test failures with NimScript.
* Set clang as cc in nim.cfg and use gmake to build csources.
* Add getCurrentDir to nimscript.
* Remove duplicate getCurrentDir and check for not weirdTarget.
* Add CI badge for OpenBSD.
* Disable tests which allocate lots of memory for OpenBSD.
* Use `CORO_BACKEND_SETJMP` on OpenBSD rather than ucontext.
* Simplify building of koch
* Disable t8657 on OpenBSD. See issue #13760.
* Fix #12142 - tarray_of_channels fails on OpenBSD
* Disable thhtpclient_ssl and tosprocterminate on OpenBSD. These tests can be enabled at a later date after fixing them.
* Install libffi.
* Set path to libc for openbsd.
* Disable tevalffi for now.
* Remove tevalffi.nim.
* Use ncpuonline sysctl rather than ncpu.
* Disable tacceptcloserace and tasynchttpserver on OpenBSD.
* Enable tacceptcloserace and tasynchttpserver.
* Fix #13775 as suggested by @alaviss - use /bin/cat on OpenBSD rather than /bin/sh.
* Enable test on OpenBSD.
* Disable tflowvar on OpenBSD.
2020-04-21 15:05:21 +02:00
Araq
5300baae06 use nimEmulateOverflowChecks for ARM/ARM64 2020-03-24 09:46:54 +01:00
Miran
c6d5f0df8d [backport] -d:danger should imply -d:release (#13336) 2020-02-05 13:41:16 +01:00
genotrance
7cc03b43f8 Fix #10717, fix #13284 (#13307) 2020-02-04 17:38:24 +01:00
Clyybber
451c47634c Fix docs for subdirs too (#13180)
* Fix doc subdirs
* Extract to helper proc, and fix on windows
2020-01-17 16:49:37 +01:00
Clyybber
41cf609fc7 Fix docs (#13176) 2020-01-16 22:22:17 +01:00
Timothee Cour
1b54be7779 fixes #12998 nim doc regression (#13117) 2020-01-16 14:19:58 +01:00
Andreas Rumpf
c282cee4db feature dracula themed doc (#12816)
* Implement gorgeous Dracula themed Nim documentation

* Add color for escape sequences

* fixes the test cases

* the big CSS cleanup
2019-12-10 06:48:11 +01:00
Elliot Waite
5da27a891c Removing the mention of using discard for block comments (#12837) [backport]
* Remove mention of using `discard` for block comments

* Add a 32x32 alternate favicon
2019-12-08 20:16:17 +01:00
genotrance
010067f3cc Substitute $nimbleDir in --path flags (#12750) 2019-11-28 13:58:38 +01:00
Tomohiro
f3b56e7ac0 Add /nologo option when nim call cl.exe (#12524) 2019-10-27 11:36:38 +01:00
Tomohiro
6b157e5f73 Fix vcc linker option name (#12422) 2019-10-18 16:20:18 +02:00
Juan Carlos
4a0debfe87 Add no-ident for GCC when -d:release (#12454) 2019-10-18 14:13:55 +02:00
Araq
ddc155af64 fixes #12040 2019-08-27 10:20:12 +02:00
Hugo Locurcio
0a1cb631a2 Implement some custom formatting for input fields in the documentation (#11632)
* Implement some custom formatting for input fields in the documentation

Aside of resulting in more consistent appearance across browsers,
this also fixes input form rendering when using Firefox with a
dark system theme on Linux.

* change the expected html in the tests
2019-07-03 07:40:24 +02:00
alaviss
e9a23cee0a nim.cfg: disable excessiveStackTrace on release (#11575) 2019-06-25 00:22:30 +02:00
Miran
7cf9b522b5 [bugfix] rename Nimrod to Nim, fix #11460 (#11462) 2019-06-10 12:54:43 +02:00
Andreas Rumpf
7215341190 make fullpaths the default in error messages and stack traces for mor… (#11385)
* make fullpaths the default in error messages and stack traces for more convenient development
* split up -d:release into -d:release and -d:danger flags
* workaround a Nim config parser bug
* fixes an old nim config parser bug
* make megatest green again
* make nimpretty tests work again
* make nimsuggest green
2019-06-05 08:02:54 +02:00