Commit Graph

6288 Commits

Author SHA1 Message Date
Andrew Kelley
d15a71afc9
generated docs: clean up type names and param names
closes #3410
2019-10-10 15:42:40 -04:00
LemonBoy
6cbb732b59 Extern unions should not trigger active field check
Fixes #3378
2019-10-10 13:57:48 -04:00
Andrew Kelley
4e81df12c3
generated docs: css: wider tables 2019-10-10 13:40:17 -04:00
Andrew Kelley
57fb550324
Merge branch 'Vexu-docs-union-enum' 2019-10-10 13:36:56 -04:00
Andrew Kelley
78d06ec4af
Merge branch 'docs-union-enum' of https://github.com/Vexu/zig into Vexu-docs-union-enum 2019-10-10 13:36:37 -04:00
Andrew Kelley
6330dfbea6
generated docs: better listing of functions 2019-10-10 11:03:16 -04:00
Andrew Kelley
b9d63551de
Merge pull request #3420 from FireFox317/generated-docs-improvements
Generated docs: add parameter names to functions
2019-10-10 10:34:44 -04:00
Michael Dusan
3464351d1e stage1: fix ir_resolve_str() to return slice
`ir_resolve_str()` bug returns array expression even when when sliced
to a lesser length. Fix is to return array if slice.len == array.len,
otherwise return slice.

Bug report use-case is based on one builtin function. However, at least
the following builtins were exposed to the bug:

    `@byteOffsetOf`
    `@cDefine`
    `@cImport`
    `@cInclude`
    `@cUndef`
    `@compileError`
    `@embedFile`
    `@export`
    `@fieldParentPtr`
    `@hasDecl`
    `@hasField`
    `@import`
    `@unionInit`

closes #3384
2019-10-10 10:20:04 -04:00
Michael Dusan
fd94d78ffc cleanup: unused imports in test 2019-10-10 10:16:35 -04:00
Timon Kruiper
e34e3344d4 Generated docs: Add function paramater names 2019-10-10 15:23:24 +02:00
Timon Kruiper
4250d27fe5 Generated docs: store static container info in a containerDecl astNode
And then get the struct field astNodes through the containerDecl astNode.
The type of a struct field is still stored in the types array, but the
static information is in the astNodes.
2019-10-10 14:21:35 +02:00
Vexu
2b55484f3f
implement doc generation for union and enum 2019-10-10 10:27:12 +03:00
Andrew Kelley
12ed85d0d1
generated docs: better handle when root is std 2019-10-10 01:38:20 -04:00
Andrew Kelley
510b6443ba
generated docs: avoid clobbering browser shortcut keys 2019-10-09 18:28:50 -04:00
Andrew Kelley
000a1df4a3
generated docs: add array type support
See #3404
2019-10-09 18:22:46 -04:00
Andrew Kelley
6d54e8fc3c
generated docs: render values
also fix pressing enter in search box before search finishes

closes #3409
2019-10-09 18:09:35 -04:00
Andrew Kelley
13ae7d47b7
generated docs: refactor how type kinds work 2019-10-09 18:09:35 -04:00
Michael Dusan
42f2814d9a stage1: fix root top-level-struct typename
- during diagnostics the string representation for root was empty
  and now is `(root)`
- retrofitted all other namespace-qualified type naming to elide
  prefixing with root

closes #2032
2019-10-09 17:36:13 -04:00
Andrew Kelley
e0ab685467
generated docs: more verbose fields
also prevent docs making hyperlinks for integer types
2019-10-09 16:31:20 -04:00
Andrew Kelley
8d5e3a2f33
generated docs: separate section for namespaces
if a type is a struct with no fields, then it goes in the namespaces
section.
2019-10-09 15:52:55 -04:00
Andrew Kelley
c4e4fa2287
zig build: bump default max exec output size to 400 KB
closes #3415
2019-10-09 15:24:15 -04:00
Andrew Kelley
3ce83e879b
generated docs: show error sets pages
also favicon, improve error sets css, syntax awareness of
noreturn
2019-10-09 15:23:13 -04:00
Andrew Kelley
a5714ddb97
add comments about why we choose pentium4 for i386 target
See #3389
2019-10-09 15:06:37 -04:00
Andrew Kelley
2286003666
improve names of error sets when using merge error sets operator 2019-10-09 13:35:19 -04:00
Timon Kruiper
8a547d9e81 Docs: adds docs comments to struct fields 2019-10-09 13:27:06 -04:00
Andrew Kelley
406b70aa56
Merge pull request #3390 from nrdmn/unicode_character_literals
unicode character literals
2019-10-09 13:25:41 -04:00
Andrew Kelley
f929a58d5f
Merge pull request #3389 from LemonBoy/win32
Win32
2019-10-09 13:22:16 -04:00
Alva
0fc97015e2 Correct std.os.connect_async docs 2019-10-09 13:15:39 -04:00
Andrew Kelley
48f5b21e7c
generated docs: functions in a table with descriptions 2019-10-09 00:24:58 -04:00
Andrew Kelley
71fb4ef8da
generated docs: separate Error Sets from Types 2019-10-08 23:33:19 -04:00
Andrew Kelley
1586f244c4
generated docs: render var decls 2019-10-08 23:24:50 -04:00
Andrew Kelley
5e765356a7
generated docs: global vars in a table 2019-10-08 23:15:47 -04:00
Andrew Kelley
ca3250a57c
generated docs: add global variables
See #3409
2019-10-08 22:39:12 -04:00
Andrew Kelley
cdaaf7c725
generated docs: consistent coloring 2019-10-08 19:04:35 -04:00
Andrew Kelley
e0f0e2aace
generated docs: error sets in fn docs 2019-10-08 18:09:08 -04:00
Timon Kruiper
f74c29b49a Add initial support for struct fields in the docs 2019-10-08 17:29:03 -04:00
Christine Dodrill
1e59eb3c94 src/main: minor grammar fix in the help for zig builtin 2019-10-08 15:14:10 -04:00
Andrew Kelley
784a493dc7
generated docs: functions with inferred error sets display nicely
infrastructure in place for displaying error sets
2019-10-08 13:41:13 -04:00
Andrew Kelley
03a6b33a73
generated docs: bool type and fix error for some fns 2019-10-08 11:59:55 -04:00
Andrew Kelley
6814d6b332
generated docs: function parameters have links 2019-10-08 11:52:06 -04:00
Andrew Kelley
a55db08a7b
generated docs contain generic instantiations and comptime calls 2019-10-08 00:15:16 -04:00
Andrew Kelley
ffc0c26b27
generated docs: highlight active package 2019-10-08 00:15:16 -04:00
Andrew Kelley
2e26aaa70c
generated docs: prioritized sort ranking 2019-10-08 00:15:14 -04:00
Andrew Kelley
7688100b17 stage1: enable PIC for libuserland
we don't really have a way to determine whether the stage1
zig compiler requires PIC so to be safe we always enable it
when building libuserland.

fixes build on some configurations of alpine linux.
2019-10-08 00:06:28 -04:00
Andrew Kelley
15471531d0
generated docs: sort search results 2019-10-07 18:17:06 -04:00
Andrew Kelley
478e53911d
generated docs: smart ignore case 2019-10-07 18:12:28 -04:00
Andrew Kelley
9df0d53981
generated docs: search cleanup 2019-10-07 18:00:01 -04:00
Andrew Kelley
4a97558ae8
generated docs: navigable search results 2019-10-07 17:46:22 -04:00
Andrew Kelley
d46234ef72
generated docs: keyboard shortcuts modal 2019-10-07 15:41:45 -04:00
Andrew Kelley
16de5a7228
generated docs: fix search stuff 2019-10-07 14:47:59 -04:00