Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita0d2f05

Browse files
committed
Improve comments for TSLexeme data structure.
Mostly, clean up long-ago pgindent damage.
1 parent515e813 commita0d2f05

File tree

1 file changed

+19
-8
lines changed

1 file changed

+19
-8
lines changed

‎src/include/tsearch/ts_public.h

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -85,20 +85,31 @@ extern bool searchstoplist(StopList *s, char *key);
8585
/* return struct for any lexize function */
8686
typedefstruct
8787
{
88-
/*
89-
* number of variant of split word , for example Word 'fotballklubber'
90-
* (norwegian) has two varian to split: ( fotball, klubb ) and ( fot,
91-
* ball, klubb ). So, dictionary should return: nvariant lexeme 1 fotball
92-
* 1 klubb 2 fot 2 ball 2 klubb
88+
/*----------
89+
* Number of current variant of split word. For example the Norwegian
90+
* word 'fotballklubber' has two variants to split: ( fotball, klubb )
91+
* and ( fot, ball, klubb ). So, dictionary should return:
92+
*
93+
* nvariant lexeme
94+
* 1 fotball
95+
* 1 klubb
96+
* 2 fot
97+
* 2 ball
98+
* 2 klubb
99+
*
100+
* In general, a TSLexeme will be considered to belong to the same split
101+
* variant as the previous one if they have the same nvariant value.
102+
* The exact values don't matter, only changes from one lexeme to next.
103+
*----------
93104
*/
94105
uint16nvariant;
95106

96-
uint16flags;
107+
uint16flags;/* See flag bits below */
97108

98-
/* C-string */
99-
char*lexeme;
109+
char*lexeme;/* C string */
100110
}TSLexeme;
101111

112+
/* Flag bits that can appear in TSLexeme.flags */
102113
#defineTSL_ADDPOS0x01
103114
#defineTSL_PREFIX0x02
104115
#defineTSL_FILTER0x04

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp