sc_proxy.hh (12853:e23d6f09069a) sc_proxy.hh (13197:aeba6988033f)
1/*****************************************************************************
2
3 Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
4 more contributor license agreements. See the NOTICE file distributed
5 with this work for additional information regarding copyright ownership.
6 Accellera licenses this file to you under the Apache License, Version 2.0
7 (the "License"); you may not use this file except in compliance with the
8 License. You may obtain a copy of the License at

--- 802 unchanged lines hidden (view full) ---

811 X &x = back_cast();
812 set_words_(x, 0, (sc_digit)a, SC_DIGIT_ZERO);
813 // extend with sign(a)
814 extend_sign_w_(x, 1, (a < 0));
815 x.clean_tail();
816 return x;
817}
818
1/*****************************************************************************
2
3 Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
4 more contributor license agreements. See the NOTICE file distributed
5 with this work for additional information regarding copyright ownership.
6 Accellera licenses this file to you under the Apache License, Version 2.0
7 (the "License"); you may not use this file except in compliance with the
8 License. You may obtain a copy of the License at

--- 802 unchanged lines hidden (view full) ---

811 X &x = back_cast();
812 set_words_(x, 0, (sc_digit)a, SC_DIGIT_ZERO);
813 // extend with sign(a)
814 extend_sign_w_(x, 1, (a < 0));
815 x.clean_tail();
816 return x;
817}
818
819#if defined(SC_LONG_64)
819#if SC_LONG_64
820template <class X>
821inline X &
822sc_proxy<X>::assign_(unsigned long a)
823{
824 X &x = back_cast();
825 set_words_(x, 0, ((sc_digit)a & ~SC_DIGIT_ZERO), SC_DIGIT_ZERO);
826 if (x.size() > 1) {
827 set_words_(x, 1, ((sc_digit)(a >> SC_DIGIT_SIZE) & ~SC_DIGIT_ZERO),

--- 567 unchanged lines hidden ---
820template <class X>
821inline X &
822sc_proxy<X>::assign_(unsigned long a)
823{
824 X &x = back_cast();
825 set_words_(x, 0, ((sc_digit)a & ~SC_DIGIT_ZERO), SC_DIGIT_ZERO);
826 if (x.size() > 1) {
827 set_words_(x, 1, ((sc_digit)(a >> SC_DIGIT_SIZE) & ~SC_DIGIT_ZERO),

--- 567 unchanged lines hidden ---