Grammalecte  Diff

Differences From Artifact [e53158c191]:

To Artifact [67f8465b1e]:


390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413

414
415
416
417
418
419
420
TEST: «{{  }}Je suis partie. »
TEST: « Je suis partie.{{  }}»


# Espace avant ou après tiret
__[i]/esp(esp_avant_après_tiret)__
    ({w_1})( [-–—]|[-–—] )({w_1})  @@0,**,$
        <<- not \1.endswith("-t") and \3 != "t" >>>
        <<- (\3 == "je" and morph(\1, ":1s"))
            or (\3 == "tu" and morph(\1, ":2s"))
            or (\3 == "il" and morph(\1, ":3s"))
            or (\3 == "elle" and morph(\1, ":3s"))
            or (\3 == "on" and morph(\1, ":3s"))
            or (\3 == "nous" and morph(\1, ":1p"))
            or (\3 == "vous" and morph(\1, ":2P"))
            or (\3 == "ils" and morph(\1, ":3p"))
            or (\3 == "elles" and morph(\1, ":3p"))
        ->> \1-\3|\1 – \3|\1 — \3           # Espace superflu s’il s’agit bien d’une forme conjuguée interrogative (sinon, il manque un espace à côté du tiret).
        <<- __else__ -2>> " – | — "         # Il manque un espace à côté du tiret.

TEST: Le {{faut -il}} ?             ->> faut-il|faut – il|faut — il
TEST: qu’y {{puis -je}} ?           ->> puis-je|puis – je|puis — je
TEST: Le {{faut -il}} ?             ->> faut-il|faut – il|faut — il
TEST: qu’y {{puis -je}} ?           ->> puis-je|puis – je|puis — je



# Espaces et crochets et parenthèses
__<s>/typo(typo_espace_après_signe_ouvrant)__    "([\[(]) "  @@0 <<- ->> \1                         # Pas d’espace après ce signe.
__<s>/typo(typo_espace_avant_signe_fermant)__    " ([\])])"  <js> ([\]\)])</js>  @@1  <<- ->> \1    # Pas d’espace avant ce signe.

TEST: c’est pas trop tôt {{( }}on a failli attendre).







|
















>







390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
TEST: «{{  }}Je suis partie. »
TEST: « Je suis partie.{{  }}»


# Espace avant ou après tiret
__[i]/esp(esp_avant_après_tiret)__
    ({w_1})( [-–—]|[-–—] )({w_1})  @@0,**,$
        <<- not \1.endswith("-t") and \3 != "t" and not (\2 == " -" and \3.isdigit()) >>>
        <<- (\3 == "je" and morph(\1, ":1s"))
            or (\3 == "tu" and morph(\1, ":2s"))
            or (\3 == "il" and morph(\1, ":3s"))
            or (\3 == "elle" and morph(\1, ":3s"))
            or (\3 == "on" and morph(\1, ":3s"))
            or (\3 == "nous" and morph(\1, ":1p"))
            or (\3 == "vous" and morph(\1, ":2P"))
            or (\3 == "ils" and morph(\1, ":3p"))
            or (\3 == "elles" and morph(\1, ":3p"))
        ->> \1-\3|\1 – \3|\1 — \3           # Espace superflu s’il s’agit bien d’une forme conjuguée interrogative (sinon, il manque un espace à côté du tiret).
        <<- __else__ -2>> " – | — "         # Il manque un espace à côté du tiret.

TEST: Le {{faut -il}} ?             ->> faut-il|faut – il|faut — il
TEST: qu’y {{puis -je}} ?           ->> puis-je|puis – je|puis — je
TEST: Le {{faut -il}} ?             ->> faut-il|faut – il|faut — il
TEST: qu’y {{puis -je}} ?           ->> puis-je|puis – je|puis — je
TEST: L’exposant -127, code 0000 0000, est réservé pour zéro


# Espaces et crochets et parenthèses
__<s>/typo(typo_espace_après_signe_ouvrant)__    "([\[(]) "  @@0 <<- ->> \1                         # Pas d’espace après ce signe.
__<s>/typo(typo_espace_avant_signe_fermant)__    " ([\])])"  <js> ([\]\)])</js>  @@1  <<- ->> \1    # Pas d’espace avant ce signe.

TEST: c’est pas trop tôt {{( }}on a failli attendre).