BSD-grep和GNU-grep之间词边界差异背后的逻辑

BSD-grep和GNU-grep之间词边界差异背后的逻辑,grep,gnu,bsd,Grep,Gnu,Bsd,有人能解释/帮助我理解BSD grep和GNU grep之间的区别背后的逻辑吗?我在火柴下面添加了插入符号 $ grep --version grep (BSD grep) 2.5.1-FreeBSD $ cat t1 admin:*:80:root $ grep '\<.' t1 admin:*:80:root ^^^^^ ^^ ^^^^ $grep--版本 grep(BSD grep)2.5.1-FreeBSD $cat t1 管理员:*:80:root $grep'\使用指定

有人能解释/帮助我理解BSD grep和GNU grep之间的区别背后的逻辑吗?我在火柴下面添加了插入符号

$ grep --version
grep (BSD grep) 2.5.1-FreeBSD
$ cat t1 
admin:*:80:root
$ grep '\<.' t1
admin:*:80:root
^^^^^   ^^ ^^^^
$grep--版本
grep(BSD grep)2.5.1-FreeBSD
$cat t1
管理员:*:80:root

$grep'\使用
指定单词边界对于
BSD grep
不起作用。尝试
[[:使用
\>
指定单词边界对
BSD grep
不起作用。尝试
[[::“长期以来,我一直对单词边界的regexp匹配依赖于实现感到恼火。”。“长期以来,我一直对单词边界的regexp匹配对实现的依赖性感到恼火。”。
$ grep --version
GNU grep 2.6.3

Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

$ cat t1 
admin:*:80:root
$ grep '\<.' t1
admin:*:80:root
^       ^  ^   
$ cat t2
admin:*:80:root
sadmin:*:81:root
$ grep '\<ad' t2
admin:*:80:root
^^