LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 04-06-2007, 11:40 AM   #1
hta1984
LQ Newbie
 
Registered: Apr 2004
Location: Ankara
Distribution: suse
Posts: 9

Rep: Reputation: 0
Nasm struct usage


I defined a struct in .data segment:
Code:
section .data
    struc tree_node
        .left_child resd 1             ; reserve 1 doubleword
        .node_data resb 1              ; reserve 1 byte
        .right_child resd 1            ; reserve 1 doubleword
    endstruc
    
    node_ptr:
    istruc tree_node
        at tree_node.left_child, dd 1
        at tree_node.node_data, db 1
        at tree_node.right_child, dd 1
    iend
I want to create left and right child of node_ptr as in C and modify it when necessary.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Usage of struct in C++ caused unexpected behavior phugoid Programming 5 04-29-2006 04:46 PM
g++ and wrong struct member addresses / struct size misreporting sonajiso Linux - General 5 05-22-2004 10:16 PM
switch statement converting struct char to struct int oceaneyes2 Programming 2 12-10-2003 04:30 PM
using struct type X as pointer in struct X. worldmagic Programming 1 10-28-2003 02:06 PM
Accessing a struct inside struct cxel91a Programming 1 09-17-2003 04:24 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration