473,473 Members | 2,226 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Forgetting how to use vec

I have a small piece of Perl code that does something like this:

for($i=0;$i<length($x);$i++){
vec($y,$i*7,8)=vec($x,$i*8,8);
}

But it doesn't pack 7-bit data from $x into $y the way I thought it
would. Could someone enlighten me on how I'm mis-reading this? What I
really want is to pack the low 7 bits of $x into $y, with no
high-bit-padding.
Jul 19 '05 #1
0 1441

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Philip Smith | last post by:
I've read with interest the continuing debate about 'lambda' and its place in Python. Just to say that personally I think its an elegant and useful construct for many types of programming task...
1
by: Siemel Naran | last post by:
Hi. I have a file of test functions. int test1() { return 0; } int test2() return 0; } There is another function that calls all the tests.
1
by: Beacher | last post by:
Hi all, I have a form with a combo box and a button, from this combo box you select a week you would like to view a report on and hit the button. This then sets the reports filter to a specific...
13
by: 010 010 | last post by:
I found this very odd and maybe someone can explain it to me. I was using fread to scan through a binary file and pull bytes out. In the middle of a while loop, for no reason that i could...
6
by: HMS Surprise | last post by:
I imported a set of functions from a file I wrote to interpreter shell: from myFile import * Now if I change functions in this file how can I make python forget it so I can force a fresh...
2
by: Alexnb | last post by:
Lets say we have this list: funlist = and lets say I do this: if funlist: print funlist I will get the exception "list index out of range"
2
by: bakhil | last post by:
Sorry if this question has been asked before, but I didn't exactly know how to word my question in the search box to get relevant results. The app I'm working on determines what DLL to load based...
12
by: hectorchu | last post by:
Why doesn't my compiler (g++) flag something like this as an error: int main() { } ?
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.