Giter Club home page Giter Club logo

Comments (9)

lizhichao avatar lizhichao commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

from sm3-php.

DongyunLee avatar DongyunLee commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

之前纠结于字符串的左移右移和补位,现在已经解决了,是我学艺不精了。

感谢关注!

from sm3-php.

lizhichao avatar lizhichao commented on May 26, 2024

大佬把 sm2 sm3 sm4 都加上吧

from sm3-php.

DongyunLee avatar DongyunLee commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

PHP位级别的左移右移都是针对int的,根上都是对于数值的➗进制运算。字符串没法直接左移右移。
所以PHP没法直接操作位,比如给字符串添加一个1bit的0b1,只能从字符级别,通过ascii进行中转。

from sm3-php.

lizhichao avatar lizhichao commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

PHP位级别的左移右移都是针对int的,根上都是对于数值的➗进制运算。字符串没法直接左移右移。
所以PHP没法直接操作位,比如给字符串添加一个1bit的0b1,只能从字符级别,通过ascii进行中转。

$str = 'dddd';
$str.= pack('C',1);

嗯 可以加个好友沟通

from sm3-php.

lizhichao avatar lizhichao commented on May 26, 2024

@DongyunLee https://github.com/lizhichao/sm 看了看算法 重写了一个 支持文件

from sm3-php.

DongyunLee avatar DongyunLee commented on May 26, 2024

@DongyunLee https://github.com/lizhichao/sm 看了看算法 重写了一个 支持文件

拜读了大佬的项目,学到了很多,感谢 👍

from sm3-php.

DongyunLee avatar DongyunLee commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

PHP位级别的左移右移都是针对int的,根上都是对于数值的➗进制运算。字符串没法直接左移右移。
所以PHP没法直接操作位,比如给字符串添加一个1bit的0b1,只能从字符级别,通过ascii进行中转。

$str = 'dddd';
$str.= pack('C',1);

嗯 可以加个好友沟通

没找到您的联系方式,可以给个邮箱或者给我profile中的邮箱发个邮件吗?

from sm3-php.

lizhichao avatar lizhichao commented on May 26, 2024

我就喜欢造轮子的人。不过php有位运算符,不知道你说的痛点是什么?

var_dump(('aa' | 'bbb') === 'ccb');

PHP位级别的左移右移都是针对int的,根上都是对于数值的➗进制运算。字符串没法直接左移右移。
所以PHP没法直接操作位,比如给字符串添加一个1bit的0b1,只能从字符级别,通过ascii进行中转。

$str = 'dddd';
$str.= pack('C',1);

嗯 可以加个好友沟通

没找到您的联系方式,可以给个邮箱或者给我profile中的邮箱发个邮件吗?

qq群 731475644

from sm3-php.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.