How do I do literal quotes in a regex?

Hi All,

Is there a `Q[]` that can be used in a regex?

I am looking for how to get around

my $x = Q[\:\\::]; ( my $y = $x ) ~~ s/ '\\\\' /x/; say $y
\:x::

This does not work:
my $x = Q[\:\\::]; ( my $y = $x ) ~~ s/ Q[\\] /x/; say $y
\:\\::

Nor does this:
my $x = Q[\:\\::]; ( my $y = $x ) ~~ s/ [\\] /x/; say $y
x:\\::

Many thanks,
-T
0
perl6
12/7/2019 6:46:49 AM
perl.perl6.users 1384 articles. 0 followers. Follow

15 Replies
65 Views

Similar Articles

[PageSpeed] 24

--00000000000004db5b05991e73ec
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=A3 (U+=
FF62  and U+FF63)

    my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=
=EF=BD=A3 /x/; say $y
    \:\\::

The case could be made that \Q[\\] should work as well. (It would need to
be added).
(Along with \q[=E2=80=A6] and \qq[=E2=80=A6])

Note that \Q[=E2=80=A6] doesn't work in string literals currently either. W=
hile
\q[=E2=80=A6] and \qq[=E2=80=A6] do.

    > "\q[\n]\n"
    \n=E2=90=A4

    > '\n\qq[\n]'
    \n=E2=90=A4

Note that single and double quotes also work in regexs.

The three of them ('=E2=80=A6' "=E2=80=A6" =EF=BD=A2=E2=80=A6=EF=BD=A3) hav=
e a few jobs.

1. They escape spaces and other non-alphanumerics.

    > 'a     b c' ~~ / 'a b c' /
    Nil
    > 'a     b c  A B C' ~~ / :i  'a b c' /
    A B C

    > 'a b c' ~~ / 'a . c' /
    Nil
    > 'a . c' ~~ / 'a . c' /
    a . c

Note that the rules for the string literal still apply.

   > "abc\n" ~~ / 'abc\n' /
   Nil
   > "abc\n" ~~ / "abc\n" /
   abc=E2=90=A4

2. They group characters as a single atom.
(Meaning they behave a bit like [] in a regex)

    > 'abccd' ~~ / 'abc'+ d /
    Nil
    > 'abccd' ~~ / [abc]+ d /
    Nil

    > 'abccd' ~~ / abc+ d /
    abccd

    > 'abccd   abcABCabcd' ~~ / :i 'abc'+ d /
    abcABCabcd
    > 'abccd   abcABCabcd' ~~ / :i [abc]+ d /
    abcABCabcd

Note that '=E2=80=A6' in a regex behaves like '=E2=80=A6' outside of one, a=
s well as "=E2=80=A6"
behaving like "=E2=80=A6" and =EF=BD=A2=E2=80=A6=EF=BD=A3 behaving like =EF=
=BD=A2=E2=80=A6=EF=BD=A3


On Sat, Dec 7, 2019 at 12:51 AM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

> Hi All,
>
> Is there a `Q[]` that can be used in a regex?
>
> I am looking for how to get around
>
> my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ '\\\\' /x/; say $y
> \:x::
>
> This does not work:
> my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q[\\] /x/; say $y
> \:\\::
>
> Nor does this:
> my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [\\] /x/; say $y
> x:\\::
>
> Many thanks,
> -T
>

--00000000000004db5b05991e73ec
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 =
and =EF=BD=A3 (U+FF62=C2=A0 and U+FF63)<div><br></div><div>=C2=A0 =C2=A0 my=
 $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=
=A3 /x/; say $y<br>=C2=A0 =C2=A0 \:\\::<br></div><div><br></div><div>The ca=
se could be made that \Q[\\] should work as well. (It would need to be adde=
d).</div><div>(Along with \q[=E2=80=A6] and \qq[=E2=80=A6])</div><div><br><=
/div><div>Note that \Q[=E2=80=A6] doesn&#39;t work in string literals curre=
ntly either. While \q[=E2=80=A6] and \qq[=E2=80=A6] do.</div><div><br></div=
><div>=C2=A0 =C2=A0 &gt; &quot;\q[\n]\n&quot;</div><div>=C2=A0 =C2=A0 \n=E2=
=90=A4</div><div><br></div><div>=C2=A0 =C2=A0 &gt; &#39;\n\qq[\n]&#39;</div=
><div>=C2=A0 =C2=A0 \n=E2=90=A4</div><div><br></div><div>Note that single a=
nd double quotes also work in regexs.</div><div><br></div><div>The three of=
 them (&#39;=E2=80=A6&#39; &quot;=E2=80=A6&quot; =EF=BD=A2=E2=80=A6=EF=BD=
=A3) have a few jobs.</div><div><br></div><div>1. They escape spaces and ot=
her non-alphanumerics.</div><div></div><div><br></div><div>=C2=A0 =C2=A0 &g=
t; &#39;a=C2=A0 =C2=A0 =C2=A0b c&#39; ~~ / &#39;a b c&#39; /</div><div>=C2=
=A0 =C2=A0 Nil</div><div>=C2=A0 =C2=A0 &gt; &#39;a=C2=A0 =C2=A0 =C2=A0b c=
=C2=A0 A B C&#39; ~~ / :i=C2=A0 &#39;a b c&#39; /</div><div>=C2=A0 =C2=A0 A=
 B C</div><div><br></div><div>=C2=A0 =C2=A0 &gt; &#39;a b c&#39; ~~ / &#39;=
a . c&#39; /</div><div>=C2=A0 =C2=A0 Nil</div><div>=C2=A0 =C2=A0 &gt; &#39;=
a . c&#39; ~~ / &#39;a . c&#39; /</div><div>=C2=A0 =C2=A0 a . c</div><div><=
br></div><div>Note that the rules for the string literal still apply.</div>=
<div><br></div><div>=C2=A0 =C2=A0&gt; &quot;abc\n&quot; ~~ / &#39;abc\n&#39=
; /</div><div>=C2=A0 =C2=A0Nil</div><div>=C2=A0 =C2=A0&gt; &quot;abc\n&quot=
; ~~ / &quot;abc\n&quot; /</div><div>=C2=A0 =C2=A0abc=E2=90=A4</div><div><b=
r></div><div>2. They group characters as a single atom.</div><div>(Meaning =
they behave a bit like [] in a regex)</div><div><br></div><div>=C2=A0 =C2=
=A0 &gt; &#39;abccd&#39; ~~ / &#39;abc&#39;+ d /</div><div>=C2=A0 =C2=A0 Ni=
l</div>=C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / [abc]+ d /<br>=C2=A0 =C2=A0 =
Nil<div><br></div><div>=C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / abc+ d /</di=
v><div>=C2=A0 =C2=A0 abccd</div><div><br></div><div>=C2=A0 =C2=A0 &gt; &#39=
;abccd=C2=A0 =C2=A0abcABCabcd&#39; ~~ / :i &#39;abc&#39;+ d /</div><div>=C2=
=A0 =C2=A0 abcABCabcd</div><div>=C2=A0 =C2=A0 &gt; &#39;abccd=C2=A0 =C2=A0a=
bcABCabcd&#39; ~~ / :i [abc]+ d /</div><div>=C2=A0 =C2=A0 abcABCabcd</div><=
div><br></div><div>Note that &#39;=E2=80=A6&#39; in a regex behaves like &#=
39;=E2=80=A6&#39; outside of one, as well as &quot;=E2=80=A6&quot; behaving=
 like &quot;=E2=80=A6&quot; and =EF=BD=A2=E2=80=A6=EF=BD=A3 behaving like =
=EF=BD=A2=E2=80=A6=EF=BD=A3</div><div><br></div></div><br><div class=3D"gma=
il_quote"><div dir=3D"ltr" class=3D"gmail_attr">On Sat, Dec 7, 2019 at 12:5=
1 AM ToddAndMargo via perl6-users &lt;<a href=3D"mailto:perl6-users@perl.or=
g">perl6-users@perl.org</a>&gt; wrote:<br></div><blockquote class=3D"gmail_=
quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,=
204);padding-left:1ex">Hi All,<br>
<br>
Is there a `Q[]` that can be used in a regex?<br>
<br>
I am looking for how to get around<br>
<br>
my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ &#39;\\\\&#39; /x/; say $y<br>
\:x::<br>
<br>
This does not work:<br>
my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q[\\] /x/; say $y<br>
\:\\::<br>
<br>
Nor does this:<br>
my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [\\] /x/; say $y<br>
x:\\::<br>
<br>
Many thanks,<br>
-T<br>
</blockquote></div>

--00000000000004db5b05991e73ec--
0
b2gills
12/7/2019 3:02:10 PM
 > On Sat, Dec 7, 2019 at 12:51 AM ToddAndMargo via perl6-users
 > <perl6-users@perl.org <mailto:perl6-users@perl.org>> wrote:
 >
 >     Hi All,
 >
 >     Is there a `Q[]` that can be used in a regex?
 >
 >     I am looking for how to get around
 >
 >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ '\\\\' /x/; say $y
 >     \:x::
 >
 >     This does not work:
 >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q[\\] /x/; say $y
 >     \:\\::
 >
 >     Nor does this:
 >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [\\] /x/; say $y
 >     x:\\::
 >
 >     Many thanks,
 >     -T

On 2019-12-07 07:02, Brad Gilbert wrote:
> The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=A3=
 (U+FF62=C2=A0 and U+FF63)
>=20
>  =C2=A0 =C2=A0 my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x ) ~~ =
s/ =EF=BD=A2\\=EF=BD=A3 /x/; say $y
>  =C2=A0 =C2=A0 \:\\::
>=20
> The case could be made that \Q[\\] should work as well. (It would need =

> to be added).
> (Along with \q[=E2=80=A6] and \qq[=E2=80=A6])
>=20
> Note that \Q[=E2=80=A6] doesn't work in string literals currently eithe=
r. While=20
> \q[=E2=80=A6] and \qq[=E2=80=A6] do.
>=20
>  =C2=A0 =C2=A0 > "\q[\n]\n"
>  =C2=A0 =C2=A0 \n=E2=90=A4
>=20
>  =C2=A0 =C2=A0 > '\n\qq[\n]'
>  =C2=A0 =C2=A0 \n=E2=90=A4
>=20
> Note that single and double quotes also work in regexs.
>=20
> The three of them ('=E2=80=A6' "=E2=80=A6" =EF=BD=A2=E2=80=A6=EF=BD=A3)=
 have a few jobs.
>=20
> 1. They escape spaces and other non-alphanumerics.
>=20
>  =C2=A0 =C2=A0 > 'a=C2=A0 =C2=A0 =C2=A0b c' ~~ / 'a b c' /
>  =C2=A0 =C2=A0 Nil
>  =C2=A0 =C2=A0 > 'a=C2=A0 =C2=A0 =C2=A0b c=C2=A0 A B C' ~~ / :i=C2=A0 '=
a b c' /
>  =C2=A0 =C2=A0 A B C
>=20
>  =C2=A0 =C2=A0 > 'a b c' ~~ / 'a . c' /
>  =C2=A0 =C2=A0 Nil
>  =C2=A0 =C2=A0 > 'a . c' ~~ / 'a . c' /
>  =C2=A0 =C2=A0 a . c
>=20
> Note that the rules for the string literal still apply.
>=20
>  =C2=A0 =C2=A0> "abc\n" ~~ / 'abc\n' /
>  =C2=A0 =C2=A0Nil
>  =C2=A0 =C2=A0> "abc\n" ~~ / "abc\n" /
>  =C2=A0 =C2=A0abc=E2=90=A4
>=20
> 2. They group characters as a single atom.
> (Meaning they behave a bit like [] in a regex)
>=20
>  =C2=A0 =C2=A0 > 'abccd' ~~ / 'abc'+ d /
>  =C2=A0 =C2=A0 Nil
>  =C2=A0 =C2=A0 > 'abccd' ~~ / [abc]+ d /
>  =C2=A0 =C2=A0 Nil
>=20
>  =C2=A0 =C2=A0 > 'abccd' ~~ / abc+ d /
>  =C2=A0 =C2=A0 abccd
>=20
>  =C2=A0 =C2=A0 > 'abccd=C2=A0 =C2=A0abcABCabcd' ~~ / :i 'abc'+ d /
>  =C2=A0 =C2=A0 abcABCabcd
>  =C2=A0 =C2=A0 > 'abccd=C2=A0 =C2=A0abcABCabcd' ~~ / :i [abc]+ d /
>  =C2=A0 =C2=A0 abcABCabcd
>=20
> Note that '=E2=80=A6' in a regex behaves like '=E2=80=A6' outside of on=
e, as well as "=E2=80=A6"=20
> behaving like "=E2=80=A6" and =EF=BD=A2=E2=80=A6=EF=BD=A3 behaving like=
 =EF=BD=A2=E2=80=A6=EF=BD=A3

Hi Brad,

   That was above and beyond!  Thank you!

my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say=
 $y
\:x::

    What is the easiest way to get those weird brackets in Fedora31?

-T
0
perl6
12/8/2019 12:54:30 PM
--000000000000b690b805993201c5
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

I would recommend setting up a compose key.

But that is not enough because I don't think it has a binding for those two
characters.

So you would also have to modify the config to include them.

I think that =EF=BD=A2Compose [ [ =EF=BD=A3 and =EF=BD=A2Compose ] ] =EF=BD=
=A3 might be what I would set
them as.

Note that =EF=BD=A2=E2=80=98=EF=BD=A3 is =EF=BD=A2Compose < ' =EF=BD=A3 and=
  =EF=BD=A2=E2=80=99=EF=BD=A3 is =EF=BD=A2Compose > ' =EF=BD=A3 along with =
=EF=BD=A2=E2=80=9C=EF=BD=A3
and =EF=BD=A2=E2=80=9D=EF=BD=A3 being =EF=BD=A2Compose < " =EF=BD=A3 and =
=EF=BD=A2Compose > " =EF=BD=A3



Personally though I just use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=A3 a=
nd =EF=BD=A2Ctrl+Shift+u
f f 6 3 Space=EF=BD=A3

So basically I just remember how to directly type in Unicode codepoints,
and those the two codepoints.

On Sun, Dec 8, 2019 at 6:56 AM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

>  > On Sat, Dec 7, 2019 at 12:51 AM ToddAndMargo via perl6-users
>  > <perl6-users@perl.org <mailto:perl6-users@perl.org>> wrote:
>  >
>  >     Hi All,
>  >
>  >     Is there a `Q[]` that can be used in a regex?
>  >
>  >     I am looking for how to get around
>  >
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ '\\\\' /x/; say $y
>  >     \:x::
>  >
>  >     This does not work:
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q[\\] /x/; say $y
>  >     \:\\::
>  >
>  >     Nor does this:
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [\\] /x/; say $y
>  >     x:\\::
>  >
>  >     Many thanks,
>  >     -T
>
> On 2019-12-07 07:02, Brad Gilbert wrote:
> > The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=A3=
 (U+FF62  and U+FF63)
> >
> >      my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x ) ~~ s/ =EF=BD=
=A2\\=EF=BD=A3 /x/; say $y
> >      \:\\::
> >
> > The case could be made that \Q[\\] should work as well. (It would need
> > to be added).
> > (Along with \q[=E2=80=A6] and \qq[=E2=80=A6])
> >
> > Note that \Q[=E2=80=A6] doesn't work in string literals currently eithe=
r. While
> > \q[=E2=80=A6] and \qq[=E2=80=A6] do.
> >
> >      > "\q[\n]\n"
> >      \n=E2=90=A4
> >
> >      > '\n\qq[\n]'
> >      \n=E2=90=A4
> >
> > Note that single and double quotes also work in regexs.
> >
> > The three of them ('=E2=80=A6' "=E2=80=A6" =EF=BD=A2=E2=80=A6=EF=BD=A3)=
 have a few jobs.
> >
> > 1. They escape spaces and other non-alphanumerics.
> >
> >      > 'a     b c' ~~ / 'a b c' /
> >      Nil
> >      > 'a     b c  A B C' ~~ / :i  'a b c' /
> >      A B C
> >
> >      > 'a b c' ~~ / 'a . c' /
> >      Nil
> >      > 'a . c' ~~ / 'a . c' /
> >      a . c
> >
> > Note that the rules for the string literal still apply.
> >
> >     > "abc\n" ~~ / 'abc\n' /
> >     Nil
> >     > "abc\n" ~~ / "abc\n" /
> >     abc=E2=90=A4
> >
> > 2. They group characters as a single atom.
> > (Meaning they behave a bit like [] in a regex)
> >
> >      > 'abccd' ~~ / 'abc'+ d /
> >      Nil
> >      > 'abccd' ~~ / [abc]+ d /
> >      Nil
> >
> >      > 'abccd' ~~ / abc+ d /
> >      abccd
> >
> >      > 'abccd   abcABCabcd' ~~ / :i 'abc'+ d /
> >      abcABCabcd
> >      > 'abccd   abcABCabcd' ~~ / :i [abc]+ d /
> >      abcABCabcd
> >
> > Note that '=E2=80=A6' in a regex behaves like '=E2=80=A6' outside of on=
e, as well as "=E2=80=A6"
> > behaving like "=E2=80=A6" and =EF=BD=A2=E2=80=A6=EF=BD=A3 behaving like=
 =EF=BD=A2=E2=80=A6=EF=BD=A3
>
> Hi Brad,
>
>    That was above and beyond!  Thank you!
>
> my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say=
 $y
> \:x::
>
>     What is the easiest way to get those weird brackets in Fedora31?
>
> -T
>

--000000000000b690b805993201c5
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">I would recommend setting up a compose key.<div><br></div>=
<div>But that is not enough because I don&#39;t think it has a binding for =
those two characters.</div><div><br></div><div>So you would also have to mo=
dify the config to include them.</div><div><br></div><div>I think that =EF=
=BD=A2Compose=C2=A0[ [ =EF=BD=A3 and =EF=BD=A2Compose ] ] =EF=BD=A3 might b=
e what I would set them as.</div><div><br></div><div>Note that =EF=BD=A2=E2=
=80=98=EF=BD=A3 is =EF=BD=A2Compose &lt; &#39; =EF=BD=A3 and=C2=A0 =EF=BD=
=A2=E2=80=99=EF=BD=A3 is =EF=BD=A2Compose &gt; &#39; =EF=BD=A3 along with =
=EF=BD=A2=E2=80=9C=EF=BD=A3 and =EF=BD=A2=E2=80=9D=EF=BD=A3 being =EF=BD=A2=
Compose &lt; &quot; =EF=BD=A3 and =EF=BD=A2Compose &gt; &quot; =EF=BD=A3</d=
iv><div><br></div><div><br></div><div><br></div><div>Personally though I ju=
st use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=A3 and =EF=BD=A2Ctrl+Shift=
+u f f 6 3 Space=EF=BD=A3</div><div><br></div><div>So basically I just reme=
mber=C2=A0how to directly type in Unicode codepoints, and those the two cod=
epoints.</div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=
=3D"gmail_attr">On Sun, Dec 8, 2019 at 6:56 AM ToddAndMargo via perl6-users=
 &lt;<a href=3D"mailto:perl6-users@perl.org">perl6-users@perl.org</a>&gt; w=
rote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0p=
x 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">=C2=A0&gt;=
 On Sat, Dec 7, 2019 at 12:51 AM ToddAndMargo via perl6-users<br>
=C2=A0&gt; &lt;<a href=3D"mailto:perl6-users@perl.org" target=3D"_blank">pe=
rl6-users@perl.org</a> &lt;mailto:<a href=3D"mailto:perl6-users@perl.org" t=
arget=3D"_blank">perl6-users@perl.org</a>&gt;&gt; wrote:<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Hi All,<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Is there a `Q[]` that can be used in a regex?=
<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0I am looking for how to get around<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ &=
#39;\\\\&#39; /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0\:x::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0This does not work:<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q=
[\\] /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0\:\\::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Nor does this:<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [=
\\] /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0x:\\::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Many thanks,<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0-T<br>
<br>
On 2019-12-07 07:02, Brad Gilbert wrote:<br>
&gt; The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=
=A3 (U+FF62=C2=A0 and U+FF63)<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x=
 ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say $y<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \:\\::<br>
&gt; <br>
&gt; The case could be made that \Q[\\] should work as well. (It would need=
 <br>
&gt; to be added).<br>
&gt; (Along with \q[=E2=80=A6] and \qq[=E2=80=A6])<br>
&gt; <br>
&gt; Note that \Q[=E2=80=A6] doesn&#39;t work in string literals currently =
either. While <br>
&gt; \q[=E2=80=A6] and \qq[=E2=80=A6] do.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &quot;\q[\n]\n&quot;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \n=E2=90=A4<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;\n\qq[\n]&#39;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \n=E2=90=A4<br>
&gt; <br>
&gt; Note that single and double quotes also work in regexs.<br>
&gt; <br>
&gt; The three of them (&#39;=E2=80=A6&#39; &quot;=E2=80=A6&quot; =EF=BD=A2=
=E2=80=A6=EF=BD=A3) have a few jobs.<br>
&gt; <br>
&gt; 1. They escape spaces and other non-alphanumerics.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a=C2=A0 =C2=A0 =C2=A0b c&#39; ~~ / &#39;=
a b c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a=C2=A0 =C2=A0 =C2=A0b c=C2=A0 A B C&#39=
; ~~ / :i=C2=A0 &#39;a b c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 A B C<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a b c&#39; ~~ / &#39;a . c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a . c&#39; ~~ / &#39;a . c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 a . c<br>
&gt; <br>
&gt; Note that the rules for the string literal still apply.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0&gt; &quot;abc\n&quot; ~~ / &#39;abc\n&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0&gt; &quot;abc\n&quot; ~~ / &quot;abc\n&quot; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0abc=E2=90=A4<br>
&gt; <br>
&gt; 2. They group characters as a single atom.<br>
&gt; (Meaning they behave a bit like [] in a regex)<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / &#39;abc&#39;+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / [abc]+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / abc+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abccd<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd=C2=A0 =C2=A0abcABCabcd&#39; ~~ / :=
i &#39;abc&#39;+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abcABCabcd<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd=C2=A0 =C2=A0abcABCabcd&#39; ~~ / :=
i [abc]+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abcABCabcd<br>
&gt; <br>
&gt; Note that &#39;=E2=80=A6&#39; in a regex behaves like &#39;=E2=80=A6&#=
39; outside of one, as well as &quot;=E2=80=A6&quot; <br>
&gt; behaving like &quot;=E2=80=A6&quot; and =EF=BD=A2=E2=80=A6=EF=BD=A3 be=
having like =EF=BD=A2=E2=80=A6=EF=BD=A3<br>
<br>
Hi Brad,<br>
<br>
=C2=A0 =C2=A0That was above and beyond!=C2=A0 Thank you!<br>
<br>
my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say $=
y<br>
\:x::<br>
<br>
=C2=A0 =C2=A0 What is the easiest way to get those weird brackets in Fedora=
31?<br>
<br>
-T<br>
</blockquote></div>

--000000000000b690b805993201c5--
0
b2gills
12/8/2019 2:22:08 PM
--0000000000002bce9605993406fd
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

You won't believe it :-) but Raku's wonderful documentation has a page on
how to enter Unicode characters:

https://docs.raku.org/language/unicode_entry

That page also links to a GitHub project which offers a .XCompose ready to
use.
I started from that and added some faster and easier (for me) to remember
key combinations, such as for example:

<Super_L> <L>                  : "=EF=BD=A2"   UFF62
<Super_L> <l>                  : "=EF=BD=A3"   UFF63

which use the left "Win" key as a dead key, followed by 'l' or 'L' to
produce the Japanese quoting characters.

On Sun, Dec 8, 2019 at 1:56 PM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

>  > On Sat, Dec 7, 2019 at 12:51 AM ToddAndMargo via perl6-users
>  > <perl6-users@perl.org <mailto:perl6-users@perl.org>> wrote:
>  >
>  >     Hi All,
>  >
>  >     Is there a `Q[]` that can be used in a regex?
>  >
>  >     I am looking for how to get around
>  >
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ '\\\\' /x/; say $y
>  >     \:x::
>  >
>  >     This does not work:
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q[\\] /x/; say $y
>  >     \:\\::
>  >
>  >     Nor does this:
>  >     my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [\\] /x/; say $y
>  >     x:\\::
>  >
>  >     Many thanks,
>  >     -T
>
> On 2019-12-07 07:02, Brad Gilbert wrote:
> > The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=A3=
 (U+FF62  and U+FF63)
> >
> >      my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x ) ~~ s/ =EF=BD=
=A2\\=EF=BD=A3 /x/; say $y
> >      \:\\::
> >
> > The case could be made that \Q[\\] should work as well. (It would need
> > to be added).
> > (Along with \q[=E2=80=A6] and \qq[=E2=80=A6])
> >
> > Note that \Q[=E2=80=A6] doesn't work in string literals currently eithe=
r. While
> > \q[=E2=80=A6] and \qq[=E2=80=A6] do.
> >
> >      > "\q[\n]\n"
> >      \n=E2=90=A4
> >
> >      > '\n\qq[\n]'
> >      \n=E2=90=A4
> >
> > Note that single and double quotes also work in regexs.
> >
> > The three of them ('=E2=80=A6' "=E2=80=A6" =EF=BD=A2=E2=80=A6=EF=BD=A3)=
 have a few jobs.
> >
> > 1. They escape spaces and other non-alphanumerics.
> >
> >      > 'a     b c' ~~ / 'a b c' /
> >      Nil
> >      > 'a     b c  A B C' ~~ / :i  'a b c' /
> >      A B C
> >
> >      > 'a b c' ~~ / 'a . c' /
> >      Nil
> >      > 'a . c' ~~ / 'a . c' /
> >      a . c
> >
> > Note that the rules for the string literal still apply.
> >
> >     > "abc\n" ~~ / 'abc\n' /
> >     Nil
> >     > "abc\n" ~~ / "abc\n" /
> >     abc=E2=90=A4
> >
> > 2. They group characters as a single atom.
> > (Meaning they behave a bit like [] in a regex)
> >
> >      > 'abccd' ~~ / 'abc'+ d /
> >      Nil
> >      > 'abccd' ~~ / [abc]+ d /
> >      Nil
> >
> >      > 'abccd' ~~ / abc+ d /
> >      abccd
> >
> >      > 'abccd   abcABCabcd' ~~ / :i 'abc'+ d /
> >      abcABCabcd
> >      > 'abccd   abcABCabcd' ~~ / :i [abc]+ d /
> >      abcABCabcd
> >
> > Note that '=E2=80=A6' in a regex behaves like '=E2=80=A6' outside of on=
e, as well as "=E2=80=A6"
> > behaving like "=E2=80=A6" and =EF=BD=A2=E2=80=A6=EF=BD=A3 behaving like=
 =EF=BD=A2=E2=80=A6=EF=BD=A3
>
> Hi Brad,
>
>    That was above and beyond!  Thank you!
>
> my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say=
 $y
> \:x::
>
>     What is the easiest way to get those weird brackets in Fedora31?
>
> -T
>


--=20
Fernando Santagata

--0000000000002bce9605993406fd
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_default" style=3D"color:#000000">You w=
on&#39;t believe it :-) but Raku&#39;s wonderful documentation has a page o=
n how to enter Unicode characters:</div><div class=3D"gmail_default" style=
=3D"color:#000000"><br></div><div class=3D"gmail_default" style=3D"color:#0=
00000"><a href=3D"https://docs.raku.org/language/unicode_entry">https://doc=
s.raku.org/language/unicode_entry</a></div><div class=3D"gmail_default" sty=
le=3D"color:#000000"><br></div><div class=3D"gmail_default" style=3D"color:=
#000000">That page also links to a GitHub project which offers a .XCompose =
ready to use.</div><div class=3D"gmail_default" style=3D"color:#000000">I s=
tarted from that and added some faster and easier (for me) to remember key =
combinations, such as for example:</div><div class=3D"gmail_default" style=
=3D"color:#000000"><br></div><div class=3D"gmail_default" style=3D"color:#0=
00000">&lt;Super_L&gt; &lt;L&gt; =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =
=C2=A0 =C2=A0 =C2=A0: &quot;=EF=BD=A2&quot; =C2=A0 UFF62<br>&lt;Super_L&gt;=
 &lt;l&gt; =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0: =
&quot;=EF=BD=A3&quot; =C2=A0 UFF63</div><div class=3D"gmail_default" style=
=3D"color:#000000"><br></div><div class=3D"gmail_default" style=3D"color:#0=
00000">which use the left &quot;Win&quot; key as a dead key, followed by &#=
39;l&#39; or &#39;L&#39; to produce the Japanese quoting characters.<br></d=
iv></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_att=
r">On Sun, Dec 8, 2019 at 1:56 PM ToddAndMargo via perl6-users &lt;<a href=
=3D"mailto:perl6-users@perl.org">perl6-users@perl.org</a>&gt; wrote:<br></d=
iv><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;bord=
er-left:1px solid rgb(204,204,204);padding-left:1ex">=C2=A0&gt; On Sat, Dec=
 7, 2019 at 12:51 AM ToddAndMargo via perl6-users<br>
=C2=A0&gt; &lt;<a href=3D"mailto:perl6-users@perl.org" target=3D"_blank">pe=
rl6-users@perl.org</a> &lt;mailto:<a href=3D"mailto:perl6-users@perl.org" t=
arget=3D"_blank">perl6-users@perl.org</a>&gt;&gt; wrote:<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Hi All,<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Is there a `Q[]` that can be used in a regex?=
<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0I am looking for how to get around<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ &=
#39;\\\\&#39; /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0\:x::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0This does not work:<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ Q=
[\\] /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0\:\\::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Nor does this:<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ [=
\\] /x/; say $y<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0x:\\::<br>
=C2=A0&gt;<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0Many thanks,<br>
=C2=A0&gt;=C2=A0 =C2=A0 =C2=A0-T<br>
<br>
On 2019-12-07 07:02, Brad Gilbert wrote:<br>
&gt; The shortcut spelling of Q[=E2=80=A6] is to use =EF=BD=A2 and =EF=BD=
=A3 (U+FF62=C2=A0 and U+FF63)<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 my $x =3D =EF=BD=A2\:\\::=EF=BD=A3; ( my $y =3D $x=
 ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say $y<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \:\\::<br>
&gt; <br>
&gt; The case could be made that \Q[\\] should work as well. (It would need=
 <br>
&gt; to be added).<br>
&gt; (Along with \q[=E2=80=A6] and \qq[=E2=80=A6])<br>
&gt; <br>
&gt; Note that \Q[=E2=80=A6] doesn&#39;t work in string literals currently =
either. While <br>
&gt; \q[=E2=80=A6] and \qq[=E2=80=A6] do.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &quot;\q[\n]\n&quot;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \n=E2=90=A4<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;\n\qq[\n]&#39;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 \n=E2=90=A4<br>
&gt; <br>
&gt; Note that single and double quotes also work in regexs.<br>
&gt; <br>
&gt; The three of them (&#39;=E2=80=A6&#39; &quot;=E2=80=A6&quot; =EF=BD=A2=
=E2=80=A6=EF=BD=A3) have a few jobs.<br>
&gt; <br>
&gt; 1. They escape spaces and other non-alphanumerics.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a=C2=A0 =C2=A0 =C2=A0b c&#39; ~~ / &#39;=
a b c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a=C2=A0 =C2=A0 =C2=A0b c=C2=A0 A B C&#39=
; ~~ / :i=C2=A0 &#39;a b c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 A B C<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a b c&#39; ~~ / &#39;a . c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;a . c&#39; ~~ / &#39;a . c&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 a . c<br>
&gt; <br>
&gt; Note that the rules for the string literal still apply.<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0&gt; &quot;abc\n&quot; ~~ / &#39;abc\n&#39; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0&gt; &quot;abc\n&quot; ~~ / &quot;abc\n&quot; /<br>
&gt;=C2=A0 =C2=A0 =C2=A0abc=E2=90=A4<br>
&gt; <br>
&gt; 2. They group characters as a single atom.<br>
&gt; (Meaning they behave a bit like [] in a regex)<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / &#39;abc&#39;+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / [abc]+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 Nil<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd&#39; ~~ / abc+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abccd<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd=C2=A0 =C2=A0abcABCabcd&#39; ~~ / :=
i &#39;abc&#39;+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abcABCabcd<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; &#39;abccd=C2=A0 =C2=A0abcABCabcd&#39; ~~ / :=
i [abc]+ d /<br>
&gt;=C2=A0 =C2=A0 =C2=A0 abcABCabcd<br>
&gt; <br>
&gt; Note that &#39;=E2=80=A6&#39; in a regex behaves like &#39;=E2=80=A6&#=
39; outside of one, as well as &quot;=E2=80=A6&quot; <br>
&gt; behaving like &quot;=E2=80=A6&quot; and =EF=BD=A2=E2=80=A6=EF=BD=A3 be=
having like =EF=BD=A2=E2=80=A6=EF=BD=A3<br>
<br>
Hi Brad,<br>
<br>
=C2=A0 =C2=A0That was above and beyond!=C2=A0 Thank you!<br>
<br>
my $x =3D Q[\:\\::]; ( my $y =3D $x ) ~~ s/ =EF=BD=A2\\=EF=BD=A3 /x/; say $=
y<br>
\:x::<br>
<br>
=C2=A0 =C2=A0 What is the easiest way to get those weird brackets in Fedora=
31?<br>
<br>
-T<br>
</blockquote></div><br clear=3D"all"><br>-- <br><div dir=3D"ltr" class=3D"g=
mail_signature">Fernando Santagata</div>

--0000000000002bce9605993406fd--
0
nando
12/8/2019 4:46:32 PM
On 2019-12-08 06:22, Brad Gilbert wrote:
>=20
> Personally though I just use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=A3=
 and=20
> =EF=BD=A2Ctrl+Shift+u f f 6 3 Space=EF=BD=A3
>=20
> So basically I just remember=C2=A0how to directly type in Unicode codep=
oints,=20
> and those the two codepoints.


Taught me something new.  Thank you!
0
perl6
12/9/2019 12:15:28 AM
On 2019-12-08 08:46, Fernando Santagata wrote:
> You won't believe it :-) but Raku's wonderful documentation has a page =

> on how to enter Unicode characters:
>=20
> https://docs.raku.org/language/unicode_entry

Hi Fernando,

Oh they sure do go to town on that one!  That page is
nicely done.

What is the unicode for the subscript double quote =E2=80=9E ?
and can it be used together with the regular
quote the same as =EF=BD=A2=EF=BD=A3 ?

Thank you!

-T

Your take: for maintainability, is it better to use
these unicodes or to just stick with escaping things?
0
perl6
12/9/2019 12:24:35 AM
On 2019-12-08 06:22, Brad Gilbert wrote:
> Personally though I just use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=A3=
 and=20
> =EF=BD=A2Ctrl+Shift+u f f 6 3 Space=EF=BD=A3
>=20

Hi Brad,

Your technical opinion: is it better for maintainability
to stick with escape sequences or to use the unicodes?

I ask as I will never remember them.  I can only program
on occasion as I am a jack of all trades.

On the other hand, I currently have 190 keeper files
(no fooling, I do not liek Raku's documentation) like
the one I copied in these parts on the hashes.  191
on unicodes would not hurt.  And I do have to reference
the other 190 a lot, so it is not like it would be any
extra work. Although, I an type and when my mind gets
racing and my fingers can keep up, I really don't
like to be slowed down.

-T
0
perl6
12/9/2019 12:41:48 AM
--000000000000d0bb8605993bd001
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

I do not quite understand the question.

I told you how to directly enter unicode by remembering the codepoint.

It's still the same characters.

I would definitely recommend setting up, and getting used to Compose keys.

I use them all the time for things like =C2=AB =C2=BB =E2=80=98 =E2=80=99 =
=E2=80=9C =E2=80=9D =C2=B9=C2=B2=C2=B3=E2=81=B4=E2=81=B5=E2=81=B6=E2=81=B7=
=E2=81=B8=E2=81=B9=E2=81=B0=C2=AF=E2=81=BA=E2=89=A0

On Sun, Dec 8, 2019 at 6:46 PM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

> On 2019-12-08 06:22, Brad Gilbert wrote:
> > Personally though I just use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=
=A3 and
> > =EF=BD=A2Ctrl+Shift+u f f 6 3 Space=EF=BD=A3
> >
>
> Hi Brad,
>
> Your technical opinion: is it better for maintainability
> to stick with escape sequences or to use the unicodes?
>
> I ask as I will never remember them.  I can only program
> on occasion as I am a jack of all trades.
>
> On the other hand, I currently have 190 keeper files
> (no fooling, I do not liek Raku's documentation) like
> the one I copied in these parts on the hashes.  191
> on unicodes would not hurt.  And I do have to reference
> the other 190 a lot, so it is not like it would be any
> extra work. Although, I an type and when my mind gets
> racing and my fingers can keep up, I really don't
> like to be slowed down.
>
> -T
>

--000000000000d0bb8605993bd001
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">I do not quite understand the question.<div><br></div><div=
>I told you how to directly enter unicode by remembering the codepoint.</di=
v><div><br></div><div>It&#39;s still the same characters.</div><div><br></d=
iv><div>I would definitely recommend setting up, and getting used to Compos=
e keys.</div><div><br></div><div>I use them all the time for things like =
=C2=AB =C2=BB =E2=80=98 =E2=80=99 =E2=80=9C =E2=80=9D =C2=B9=C2=B2=C2=B3=E2=
=81=B4=E2=81=B5=E2=81=B6=E2=81=B7=E2=81=B8=E2=81=B9=E2=81=B0=C2=AF=E2=81=BA=
=E2=89=A0</div><div></div></div><br><div class=3D"gmail_quote"><div dir=3D"=
ltr" class=3D"gmail_attr">On Sun, Dec 8, 2019 at 6:46 PM ToddAndMargo via p=
erl6-users &lt;<a href=3D"mailto:perl6-users@perl.org">perl6-users@perl.org=
</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:=
0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">=
On 2019-12-08 06:22, Brad Gilbert wrote:<br>
&gt; Personally though I just use =EF=BD=A2Ctrl+Shift+u f f 6 2 Space=EF=BD=
=A3 and <br>
&gt; =EF=BD=A2Ctrl+Shift+u f f 6 3 Space=EF=BD=A3<br>
&gt; <br>
<br>
Hi Brad,<br>
<br>
Your technical opinion: is it better for maintainability<br>
to stick with escape sequences or to use the unicodes?<br>
<br>
I ask as I will never remember them.=C2=A0 I can only program<br>
on occasion as I am a jack of all trades.<br>
<br>
On the other hand, I currently have 190 keeper files<br>
(no fooling, I do not liek Raku&#39;s documentation) like<br>
the one I copied in these parts on the hashes.=C2=A0 191<br>
on unicodes would not hurt.=C2=A0 And I do have to reference<br>
the other 190 a lot, so it is not like it would be any<br>
extra work. Although, I an type and when my mind gets<br>
racing and my fingers can keep up, I really don&#39;t<br>
like to be slowed down.<br>
<br>
-T<br>
</blockquote></div>

--000000000000d0bb8605993bd001--
0
b2gills
12/9/2019 2:04:16 AM
On 2019-12-08 18:04, Brad Gilbert wrote:
> I do not quite understand the question.
>=20
> I told you how to directly enter unicode by remembering the codepoint.
>=20
> It's still the same characters.
>=20
> I would definitely recommend setting up, and getting used to Compose ke=
ys.
>=20
> I use them all the time for things like =C2=AB =C2=BB =E2=80=98 =E2=80=99=
 =E2=80=9C =E2=80=9D =C2=B9=C2=B2=C2=B3=E2=81=B4=E2=81=B5=E2=81=B6=E2=81=B7=
=E2=81=B8=E2=81=B9=E2=81=B0=C2=AF=E2=81=BA=E2=89=A0

I was not asking if they were any good or not.

I was asking if you thought someone like me, who
would have to look the them up every time, should
just stick with the what is on the keyboard.

At times I have just had a list of them I could just
copy and paste.

Be nice if Geany would have an insert character function.
(I use Geany as it is ssh X11 friendly.)
0
perl6
12/9/2019 2:12:09 AM
--000000000000c41e0705993d113d
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

I like to use them, but I am not you.

On Sun, Dec 8, 2019 at 8:19 PM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

> On 2019-12-08 18:04, Brad Gilbert wrote:
> > I do not quite understand the question.
> >
> > I told you how to directly enter unicode by remembering the codepoint.
> >
> > It's still the same characters.
> >
> > I would definitely recommend setting up, and getting used to Compose
> keys.
> >
> > I use them all the time for things like =C2=AB =C2=BB =E2=80=98 =E2=80=
=99 =E2=80=9C =E2=80=9D =C2=B9=C2=B2=C2=B3=E2=81=B4=E2=81=B5=E2=81=B6=E2=81=
=B7=E2=81=B8=E2=81=B9=E2=81=B0=C2=AF=E2=81=BA=E2=89=A0
>
> I was not asking if they were any good or not.
>
> I was asking if you thought someone like me, who
> would have to look the them up every time, should
> just stick with the what is on the keyboard.
>
> At times I have just had a list of them I could just
> copy and paste.
>
> Be nice if Geany would have an insert character function.
> (I use Geany as it is ssh X11 friendly.)
>

--000000000000c41e0705993d113d
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">I like to use them, but I am not you.</div><br><div class=
=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On Sun, Dec 8, 2019 =
at 8:19 PM ToddAndMargo via perl6-users &lt;<a href=3D"mailto:perl6-users@p=
erl.org">perl6-users@perl.org</a>&gt; wrote:<br></div><blockquote class=3D"=
gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(20=
4,204,204);padding-left:1ex">On 2019-12-08 18:04, Brad Gilbert wrote:<br>
&gt; I do not quite understand the question.<br>
&gt; <br>
&gt; I told you how to directly enter unicode by remembering the codepoint.=
<br>
&gt; <br>
&gt; It&#39;s still the same characters.<br>
&gt; <br>
&gt; I would definitely recommend setting up, and getting used to Compose k=
eys.<br>
&gt; <br>
&gt; I use them all the time for things like =C2=AB =C2=BB =E2=80=98 =E2=80=
=99 =E2=80=9C =E2=80=9D =C2=B9=C2=B2=C2=B3=E2=81=B4=E2=81=B5=E2=81=B6=E2=81=
=B7=E2=81=B8=E2=81=B9=E2=81=B0=C2=AF=E2=81=BA=E2=89=A0<br>
<br>
I was not asking if they were any good or not.<br>
<br>
I was asking if you thought someone like me, who<br>
would have to look the them up every time, should<br>
just stick with the what is on the keyboard.<br>
<br>
At times I have just had a list of them I could just<br>
copy and paste.<br>
<br>
Be nice if Geany would have an insert character function.<br>
(I use Geany as it is ssh X11 friendly.)<br>
</blockquote></div>

--000000000000c41e0705993d113d--
0
b2gills
12/9/2019 3:34:02 AM
On 2019-12-08 19:34, Brad Gilbert wrote:
> I like to use them, but I am not you.

Hi Brad,

I am going to create a keeper and give it a shot!

It is not like I don't have four or five of them
open when I am programming

:-)

-T
0
perl6
12/9/2019 6:38:17 AM
--0000000000004b7e5f059941515f
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Mon, Dec 9, 2019 at 1:27 AM ToddAndMargo via perl6-users <
perl6-users@perl.org> wrote:

> What is the unicode for the subscript double quote =E2=80=9E ?
>

That's U+201E

and can it be used together with the regular
> quote the same as =EF=BD=A2=EF=BD=A3 ?
>

It can be used this way:

$ raku -e'say =E2=80=9EHello!=E2=80=9C'
Hello!
But it must be used with that closing quote '=E2=80=9C' (U+201C); it cannot=
 be used
paired with itself:
$ raku -e'say =E2=80=9EHello!=E2=80=9E'
=3D=3D=3DSORRY!=3D=3D=3D Error while compiling -e
Unable to parse expression in low curly double quotes; couldn't find final
<[=E2=80=9D=E2=80=9C]> (corresponding starter was at line 1)
at -e:1
------> say =E2=80=9EHello!=E2=80=9E=E2=8F=8F<EOL>
    expecting any of:
        argument list
        low curly double quotes
        term

Your take: for maintainability, is it better to use
> these unicodes or to just stick with escaping things?
>

I don't think there's a maintainability issue with Unicode operators,
because everyone has a plain ASCII counterpart; besides, their meaning is
quite apparent or in some cases even better than their ASCII counterpart:
consider the set union operator =E2=88=AA vs (|), the first being the unive=
rsally
accepted mathematical symbol, while I find the second difficult to
interpret and remember.

--=20
Fernando Santagata

--0000000000004b7e5f059941515f
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail=
_attr">On Mon, Dec 9, 2019 at 1:27 AM ToddAndMargo via perl6-users &lt;<a h=
ref=3D"mailto:perl6-users@perl.org">perl6-users@perl.org</a>&gt; wrote:<br>=
</div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;b=
order-left:1px solid rgb(204,204,204);padding-left:1ex">What is the unicode=
 for the subscript double quote =E2=80=9E ?<br></blockquote><div><br></div>=
<div><div style=3D"color:rgb(0,0,0)" class=3D"gmail_default">That&#39;s U+2=
01E</div><div> <br></div></div><blockquote class=3D"gmail_quote" style=3D"m=
argin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left=
:1ex">
and can it be used together with the regular<br>
quote the same as =EF=BD=A2=EF=BD=A3 ?<br></blockquote><div><br></div><div>=
<div style=3D"color:rgb(0,0,0)" class=3D"gmail_default">It can be used this=
 way:</div><div style=3D"color:rgb(0,0,0)" class=3D"gmail_default"><br></di=
v><div style=3D"color:rgb(0,0,0)" class=3D"gmail_default">$ raku -e&#39;say=
 =E2=80=9EHello!=E2=80=9C&#39;<br>Hello!<br></div><div style=3D"color:rgb(0=
,0,0)" class=3D"gmail_default">But it must be used with that closing quote =
&#39;=E2=80=9C&#39; (U+201C); it cannot be used paired with itself:</div><d=
iv style=3D"color:rgb(0,0,0)" class=3D"gmail_default"></div><div style=3D"c=
olor:rgb(0,0,0)" class=3D"gmail_default">$ raku  -e&#39;say =E2=80=9EHello!=
=E2=80=9E&#39;<br>=3D=3D=3DSORRY!=3D=3D=3D Error while compiling -e<br>Unab=
le to parse expression in low curly double quotes; couldn&#39;t find final =
&lt;[=E2=80=9D=E2=80=9C]&gt; (corresponding starter was at line 1)<br>at -e=
:1<br>------&gt; say =E2=80=9EHello!=E2=80=9E=E2=8F=8F&lt;EOL&gt;<br>=C2=A0=
 =C2=A0 expecting any of:<br>=C2=A0 =C2=A0 =C2=A0 =C2=A0 argument list<br>=
=C2=A0 =C2=A0 =C2=A0 =C2=A0 low curly double quotes<br>=C2=A0 =C2=A0 =C2=A0=
 =C2=A0 term<br></div></div><br><blockquote class=3D"gmail_quote" style=3D"=
margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-lef=
t:1ex">
Your take: for maintainability, is it better to use<br>
these unicodes or to just stick with escaping things?<br>
</blockquote></div><br clear=3D"all"><div><div style=3D"color:rgb(0,0,0)" c=
lass=3D"gmail_default">I don&#39;t think there&#39;s a maintainability issu=
e with Unicode operators, because everyone has a plain ASCII counterpart; b=
esides, their meaning is quite apparent or in some cases even better than t=
heir ASCII counterpart: consider the set union operator =E2=88=AA vs (|), t=
he first being the universally accepted mathematical symbol, while I find t=
he second difficult to interpret and remember.<br></div></div><div><br></di=
v>-- <br><div dir=3D"ltr" class=3D"gmail_signature">Fernando Santagata</div=
></div>

--0000000000004b7e5f059941515f--
0
nando
12/9/2019 8:38:07 AM
--000000000000c1eaa40599416dac
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Mon, Dec 9, 2019 at 9:38 AM Fernando Santagata <nando.santagata@gmail.co=
m>
wrote:

> It can be used this way:
>
> $ raku -e'say =E2=80=9EHello!=E2=80=9C'
> Hello!
> But it must be used with that closing quote '=E2=80=9C' (U+201C); it cann=
ot be
> used paired with itself:
>

There's another quotation mark that can be used with '=E2=80=9E', it's '=E2=
=80=9D'
(U+201D). I know, it's difficult to see the difference :-)

$ raku -e'say =E2=80=9EHello!=E2=80=9E'
> =3D=3D=3DSORRY!=3D=3D=3D Error while compiling -e
> Unable to parse expression in low curly double quotes; couldn't find fina=
l
> <[=E2=80=9D=E2=80=9C]> (corresponding starter was at line 1)
> at -e:1
> ------> say =E2=80=9EHello!=E2=80=9E=E2=8F=8F<EOL>
>     expecting any of:
>         argument list
>         low curly double quotes
>         term
>
> Your take: for maintainability, is it better to use
>> these unicodes or to just stick with escaping things?
>>
>
> I don't think there's a maintainability issue with Unicode operators,
> because everyone has a plain ASCII counterpart; besides, their meaning is
> quite apparent or in some cases even better than their ASCII counterpart:
> consider the set union operator =E2=88=AA vs (|), the first being the uni=
versally
> accepted mathematical symbol, while I find the second difficult to
> interpret and remember.
>
> --
> Fernando Santagata
>


--=20
Fernando Santagata

--000000000000c1eaa40599416dac
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail=
_attr">On Mon, Dec 9, 2019 at 9:38 AM Fernando Santagata &lt;<a href=3D"mai=
lto:nando.santagata@gmail.com">nando.santagata@gmail.com</a>&gt; wrote:<br>=
</div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;b=
order-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir=3D"ltr"><d=
iv class=3D"gmail_quote">It can be used this way:<div><div style=3D"color:r=
gb(0,0,0)"><br></div><div style=3D"color:rgb(0,0,0)">$ raku -e&#39;say =E2=
=80=9EHello!=E2=80=9C&#39;<br>Hello!<br></div><div style=3D"color:rgb(0,0,0=
)">But it must be used with that closing quote &#39;=E2=80=9C&#39; (U+201C)=
; it cannot be used paired with itself:</div></div></div></div></blockquote=
><div><br></div><div><div style=3D"color:rgb(0,0,0)" class=3D"gmail_default=
">There&#39;s another quotation mark that can be used with &#39;=E2=80=9E&#=
39;, it&#39;s &#39;=E2=80=9D&#39; (U+201D). I know, it&#39;s difficult to s=
ee the difference :-)<br></div></div><div><br></div><blockquote class=3D"gm=
ail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,=
204,204);padding-left:1ex"><div dir=3D"ltr"><div class=3D"gmail_quote"><div=
><div style=3D"color:rgb(0,0,0)"></div><div style=3D"color:rgb(0,0,0)">$ ra=
ku  -e&#39;say =E2=80=9EHello!=E2=80=9E&#39;<br>=3D=3D=3DSORRY!=3D=3D=3D Er=
ror while compiling -e<br>Unable to parse expression in low curly double qu=
otes; couldn&#39;t find final &lt;[=E2=80=9D=E2=80=9C]&gt; (corresponding s=
tarter was at line 1)<br>at -e:1<br>------&gt; say =E2=80=9EHello!=E2=80=9E=
=E2=8F=8F&lt;EOL&gt;<br>=C2=A0 =C2=A0 expecting any of:<br>=C2=A0 =C2=A0 =
=C2=A0 =C2=A0 argument list<br>=C2=A0 =C2=A0 =C2=A0 =C2=A0 low curly double=
 quotes<br>=C2=A0 =C2=A0 =C2=A0 =C2=A0 term<br></div></div><br><blockquote =
class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px sol=
id rgb(204,204,204);padding-left:1ex">
Your take: for maintainability, is it better to use<br>
these unicodes or to just stick with escaping things?<br>
</blockquote></div><br clear=3D"all"><div><div style=3D"color:rgb(0,0,0)">I=
 don&#39;t think there&#39;s a maintainability issue with Unicode operators=
, because everyone has a plain ASCII counterpart; besides, their meaning is=
 quite apparent or in some cases even better than their ASCII counterpart: =
consider the set union operator =E2=88=AA vs (|), the first being the unive=
rsally accepted mathematical symbol, while I find the second difficult to i=
nterpret and remember.<br></div></div><div><br></div>-- <br><div dir=3D"ltr=
">Fernando Santagata</div></div>
</blockquote></div><br clear=3D"all"><br>-- <br><div dir=3D"ltr" class=3D"g=
mail_signature">Fernando Santagata</div></div>

--000000000000c1eaa40599416dac--
0
nando
12/9/2019 8:46:05 AM
--000000000000dbacc105994b5a91
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Mon, Dec 9, 2019 at 03:54 Fernando Santagata <nando.santagata@gmail.com>
wrote:

> On Mon, Dec 9, 2019 at 9:38 AM Fernando Santagata <
> nando.santagata@gmail.com> wrote:
>
>> It can be used this way:
>>
>> $ raku -e'say =E2=80=9EHello!=E2=80=9C'
>> Hello!
>> But it must be used with that closing quote '=E2=80=9C' (U+201C); it can=
not be
>> used paired with itself:
>>
>
> There's another quotation mark that can be used with '=E2=80=9E', it's '=
=E2=80=9D'
> (U+201D). I know, it's difficult to see the difference :-)
>

It=E2=80=99s easier to see in serif typefaces. Traditionally, pairing =E2=
=80=9EHello!=E2=80=9C
(with U+201C) is how German used it and =E2=80=9EHello!=E2=80=9D (with U+20=
1D) is how Dutch
used it. But those conventions aren=E2=80=99t as rigidly set as in some oth=
er
languages. In any case, it makes sense to allow either left- or
right-closing double quotation mark in closing.

--000000000000dbacc105994b5a91
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div>On Mon, Dec 9, 2019 at 03:54 Fernando Santagata &lt;<a href=3D"mailto:=
nando.santagata@gmail.com">nando.santagata@gmail.com</a>&gt; wrote:<br></di=
v><div><div class=3D"gmail_quote"><blockquote class=3D"gmail_quote" style=
=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=
=3D"ltr"><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">O=
n Mon, Dec 9, 2019 at 9:38 AM Fernando Santagata &lt;<a href=3D"mailto:nand=
o.santagata@gmail.com" target=3D"_blank">nando.santagata@gmail.com</a>&gt; =
wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0=
px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir=
=3D"ltr"><div class=3D"gmail_quote">It can be used this way:<div><div style=
=3D"color:rgb(0,0,0)"><br></div><div style=3D"color:rgb(0,0,0)">$ raku -e&#=
39;say =E2=80=9EHello!=E2=80=9C&#39;<br>Hello!<br></div><div style=3D"color=
:rgb(0,0,0)">But it must be used with that closing quote &#39;=E2=80=9C&#39=
; (U+201C); it cannot be used paired with itself:</div></div></div></div></=
blockquote><div><br></div><div><div style=3D"color:rgb(0,0,0)" class=3D"gma=
il_default">There&#39;s another quotation mark that can be used with &#39;=
=E2=80=9E&#39;, it&#39;s &#39;=E2=80=9D&#39; (U+201D). I know, it&#39;s dif=
ficult to see the difference :-)</div></div></div></div></blockquote><div d=
ir=3D"auto"><br></div><div dir=3D"auto">It=E2=80=99s easier to see in serif=
 typefaces. Traditionally, pairing =E2=80=9EHello!=E2=80=9C (with U+201C) i=
s how German used it and =E2=80=9EHello!=E2=80=9D (with U+201D) is how Dutc=
h used it. But those conventions aren=E2=80=99t as rigidly set as in some o=
ther languages. In any case, it makes sense to allow either left- or right-=
closing double quotation mark in closing.</div><div dir=3D"auto"><br></div>=
</div></div>

--000000000000dbacc105994b5a91--
0
trey
12/9/2019 8:36:38 PM
On 2019-12-09 00:46, Fernando Santagata wrote:
> On Mon, Dec 9, 2019 at 9:38 AM Fernando Santagata=20
> <nando.santagata@gmail.com <mailto:nando.santagata@gmail.com>> wrote:
>=20
>     It can be used this way:
>=20
>     $ raku -e'say =E2=80=9EHello!=E2=80=9C'
>     Hello!
>     But it must be used with that closing quote '=E2=80=9C' (U+201C); i=
t cannot
>     be used paired with itself:
>=20
>=20
> There's another quotation mark that can be used with '=E2=80=9E', it's =
'=E2=80=9D'=20
> (U+201D). I know, it's difficult to see the difference :-)
>=20
>     $ raku -e'say =E2=80=9EHello!=E2=80=9E'
>     =3D=3D=3DSORRY!=3D=3D=3D Error while compiling -e
>     Unable to parse expression in low curly double quotes; couldn't fin=
d
>     final <[=E2=80=9D=E2=80=9C]> (corresponding starter was at line 1)
>     at -e:1
>     ------> say =E2=80=9EHello!=E2=80=9E=E2=8F=8F<EOL>
>      =C2=A0 =C2=A0 expecting any of:
>      =C2=A0 =C2=A0 =C2=A0 =C2=A0 argument list
>      =C2=A0 =C2=A0 =C2=A0 =C2=A0 low curly double quotes
>      =C2=A0 =C2=A0 =C2=A0 =C2=A0 term
>=20
>         Your take: for maintainability, is it better to use
>         these unicodes or to just stick with escaping things?
>=20
>=20
>     I don't think there's a maintainability issue with Unicode
>     operators, because everyone has a plain ASCII counterpart; besides,=

>     their meaning is quite apparent or in some cases even better than
>     their ASCII counterpart: consider the set union operator =E2=88=AA =
vs (|),
>     the first being the universally accepted mathematical symbol, while=

>     I find the second difficult to interpret and remember.
>=20
>     --=20
>     Fernando Santagata
>=20
>=20
>=20
> --=20
> Fernando Santagata


Thank you!

I already have a keeper going with useful unicodes.

-T
0
perl6
12/10/2019 9:47:33 PM
Reply: