PostgreSQL Source Code git master
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
stem_KOI8_R_russian.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

struct SN_envrussian_KOI8_R_create_env (void)
 
void russian_KOI8_R_close_env (struct SN_env *z)
 
int russian_KOI8_R_stem (struct SN_env *z)
 

Function Documentation

◆ russian_KOI8_R_close_env()

void russian_KOI8_R_close_env ( struct SN_env z)

Definition at line 684 of file stem_KOI8_R_russian.c.

684{ SN_close_env(z, 0); }
void SN_close_env(struct SN_env *z, int S_size)
Definition: api.c:34

References SN_close_env().

◆ russian_KOI8_R_create_env()

struct SN_env * russian_KOI8_R_create_env ( void  )

Definition at line 682 of file stem_KOI8_R_russian.c.

682{ return SN_create_env(0, 2); }
struct SN_env * SN_create_env(int S_size, int I_size)
Definition: api.c:3

References SN_create_env().

◆ russian_KOI8_R_stem()

int russian_KOI8_R_stem ( struct SN_env z)

Definition at line 572 of file stem_KOI8_R_russian.c.

572 {
573 { int c1 = z->c;
574 while(1) {
575 int c2 = z->c;
576 while(1) {
577 int c3 = z->c;
578 z->bra = z->c;
579 if (z->c == z->l || z->p[z->c] != 0xA3) goto lab2;
580 z->c++;
581 z->ket = z->c;
582 z->c = c3;
583 break;
584 lab2:
585 z->c = c3;
586 if (z->c >= z->l) goto lab1;
587 z->c++;
588 }
589 { int ret = slice_from_s(z, 1, s_0);
590 if (ret < 0) return ret;
591 }
592 continue;
593 lab1:
594 z->c = c2;
595 break;
596 }
597 z->c = c1;
598 }
599
600 { int ret = r_mark_regions(z);
601 if (ret < 0) return ret;
602 }
603 z->lb = z->c; z->c = z->l;
604
605
606 { int mlimit4;
607 if (z->c < z->I[1]) return 0;
608 mlimit4 = z->lb; z->lb = z->I[1];
609 { int m5 = z->l - z->c; (void)m5;
610 { int m6 = z->l - z->c; (void)m6;
611 { int ret = r_perfective_gerund(z);
612 if (ret == 0) goto lab5;
613 if (ret < 0) return ret;
614 }
615 goto lab4;
616 lab5:
617 z->c = z->l - m6;
618 { int m7 = z->l - z->c; (void)m7;
619 { int ret = r_reflexive(z);
620 if (ret == 0) { z->c = z->l - m7; goto lab6; }
621 if (ret < 0) return ret;
622 }
623 lab6:
624 ;
625 }
626 { int m8 = z->l - z->c; (void)m8;
627 { int ret = r_adjectival(z);
628 if (ret == 0) goto lab8;
629 if (ret < 0) return ret;
630 }
631 goto lab7;
632 lab8:
633 z->c = z->l - m8;
634 { int ret = r_verb(z);
635 if (ret == 0) goto lab9;
636 if (ret < 0) return ret;
637 }
638 goto lab7;
639 lab9:
640 z->c = z->l - m8;
641 { int ret = r_noun(z);
642 if (ret == 0) goto lab3;
643 if (ret < 0) return ret;
644 }
645 }
646 lab7:
647 ;
648 }
649 lab4:
650 lab3:
651 z->c = z->l - m5;
652 }
653 { int m9 = z->l - z->c; (void)m9;
654 z->ket = z->c;
655 if (z->c <= z->lb || z->p[z->c - 1] != 0xC9) { z->c = z->l - m9; goto lab10; }
656 z->c--;
657 z->bra = z->c;
658 { int ret = slice_del(z);
659 if (ret < 0) return ret;
660 }
661 lab10:
662 ;
663 }
664 { int m10 = z->l - z->c; (void)m10;
665 { int ret = r_derivational(z);
666 if (ret < 0) return ret;
667 }
668 z->c = z->l - m10;
669 }
670 { int m11 = z->l - z->c; (void)m11;
671 { int ret = r_tidy_up(z);
672 if (ret < 0) return ret;
673 }
674 z->c = z->l - m11;
675 }
676 z->lb = mlimit4;
677 }
678 z->c = z->lb;
679 return 1;
680}
static int r_tidy_up(struct SN_env *z)
static int r_adjectival(struct SN_env *z)
static int r_verb(struct SN_env *z)
static int r_derivational(struct SN_env *z)
static int r_perfective_gerund(struct SN_env *z)
static int r_mark_regions(struct SN_env *z)
static int r_reflexive(struct SN_env *z)
static int r_noun(struct SN_env *z)
static const symbol s_0[]
int lb
Definition: api.h:16
symbol * p
Definition: api.h:15
int * I
Definition: api.h:18
int ket
Definition: api.h:16
int c
Definition: api.h:16
int bra
Definition: api.h:16
int l
Definition: api.h:16
int slice_del(struct SN_env *z)
Definition: utilities.c:431
int slice_from_s(struct SN_env *z, int s_size, const symbol *s)
Definition: utilities.c:422

References SN_env::bra, SN_env::c, SN_env::I, SN_env::ket, SN_env::l, SN_env::lb, SN_env::p, r_adjectival(), r_derivational(), r_mark_regions(), r_noun(), r_perfective_gerund(), r_reflexive(), r_tidy_up(), r_verb(), s_0, slice_del(), and slice_from_s().